This package has been deprecated

    Author message:

    This module is no longer maintained. Please use Next API or speak to a member of the Next team about using Elasticsearch.

    next-ft-api-client

    3.26.0 • Public • Published

    next-ft-api-client

    No caching, no models, no complexity, none of that or any of that.

    npm install --save next-ft-api-client
    
    var api = require('next-ft-api-client');

    .content(opts)

    • uuid - uuid (or array of uuids) of wanted content

    If uuid is a string return a Promise that resolves with V3 Elasticsearch content, if uuid is an array, returns a Promise that resolves with an array of content.

    .contentAnnotatedBy(opts)

    • uuid - uuid of thing wanted to select content by
    • count - number of items of content to return (default 10)

    Returns with a Promise that resolves with an array of V2 content objects.

    .lists(opts)

    • uuid - uuid of wanted list

    Returns with a Promise that resolves with a list.

    .organisations(opts)

    • uuid - uuid of wanted organisation

    Returns with a Promise that resolves with an organisation.

    .people(opts)

    • uuid - uuid of wanted person

    Returns with a Promise that resolves with a person.

    .search(opts)

    • filter - search filter. Either an array of [ fieldname, value ] or an Elasticsearch filter object.
    • fields - an array of source document fields to fetch
    • count - number of documents to return (default 10)
    • offset - number of documents to offset by (default 0)

    Returns a promise that resolves an array of documents from the V3 Elasticsearch index.

    .things(opts)

    • identifierValues - an array of source thing ids you wish to fetch
    • identifierType - property type of indetifier you wish to search on, such as prefLabel or idV1 (default 'idV1')
    • authority - the authority the terms belong too (defaults to FT-TME: http://api.ft.com/system/FT-TME)

    Returns with a Promise that resolves with an array of things.

    .mapping(uuid, taxonomy)

    • uuid - uuid of thing to map
    • taxonomy - taxonomy of thing to map

    Returns with a Promise that resolves with the mapped concept.

    .hui(opts)

    • model - string of the type of model you want returned (default 'content')
    • industry - uuid of an industry
    • position - uuid of a position
    • sector - uuid of a sector
    • country - uuid of a country
    • period - time period to use e.g last-1-day, last-1-week (default last-1-day)
    • count - number of UUIDs to return (default 10)

    Returns with a Promise that resolves with a list.

    .concordance(opts)

    • id - string of the id either TME (v1) or uuid (v2)

    If it is passed a uuid it will concord to the v1 TME. If the id is not a uuid it will concord to the V2 uuid.

    Keywords

    none

    Install

    npm i next-ft-api-client

    DownloadsWeekly Downloads

    14

    Version

    3.26.0

    License

    none

    Last publish

    Collaborators

    • financial-times
    • mattandrews