Skip to content

Companies

This page shows the different endpoints available for companies multiple actions and individual

Fetch Companies

Endpoint to return a list of companies in a paginated manner. The results can be requested by page size and the page of results requested. Total results will be sent back and so will continuation tokens, to speed up future queries these should both be included in all future requests to the endpoint.

URL

POST - https://depot-api.feeditback.com/company/companies/

Request

This is an example request showing what data will be required to be sent

json
{
  "per_page": 10, // Amount of results to be returned per page
  "page": 5, // Page number to return results of
  "total_count": 50, // Amount of results present - sent in request to speed up query
  "tokens": {} // Previously returned tokens - sent in request to speed up query
}

Details

total_count

This is not required but if you do return it the endpoint wont need to calculate the total results again resulting in a faster query

tokens

This is not required but if you do return it the endpoint will have markers as to where you last were and what pages of results have already been scraped, resulting in faster query and ensuring no results are lost.

Response

json
{
  "data": [
    {
      "name": "xxxxxxx",
      "company_uuid": "xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx"
    }
  ], // Results of search critera
  "tokens": {
    "x": ["xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx"]
  }, // Continunation tokens for search
  "has_more": true, // Details if more results can be fetched
  "total_count": 180, // Total number of results based on search critear
  "total_pages": 18 // Total number of pages based on search critera
}

Upload Companies Admin

Adds the ability to mass upload companies at a time, this is a simple CSV that should be uploaded in with the name of each company to create.

URL

POST - https://depot-api.feeditback.com/company/companies/upload

Request

This is an example request showing what data will be required to be sent

json
{
  "file": "data.csv"
}

Details

Example format of a Companies csv

Name
Starbucks
Costa

Response

json
{
  "message": "", // Number of results successfully processed
  "data": [
    {
      "name": "",
      "result": true
    }
  ] // Information for each companies processing
}

Add Company Admin

Ability to add a single company without any additonal data attached.

URL

POST - https://depot-api.feeditback.com/company/company

Request

This is an example request showing what data will be required to be sent

json
{
  "name": "" // Name of the company
}

Response

json
{
  "data": {
    "id": "", // Id for company
    "name": "" // Name of added company
  }
}

Fetch Company by ID

URL

GET - https://depot-api.feeditback.com/company/company/{id}

Response

json
{
  "data": {
    "id": "xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx", // ID of company
    "name": "xxxxxxx" // Name of company
  }
}

Fetch sites setup by Company Id Admin

URL

GET - https://depot-api.feeditback.com/company/company/{id}/sites

Response

json
{
  "data": [
    {
      "name": "xxxxxxx", // Name of site
      "address": {
        "address1": "xx xxxxx xxxxxx",
        "address2": "",
        "address3": "",
        "town": "xxxxxxx",
        "county": "xxxxxxxxx",
        "country": "xxxxxx xxxxxxx",
        "postcode": "xxx xxx"
      }, // Address of site
      "channels": [
        {
          "type": "google",
          "profile_id": "xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx"
        },
        {
          "type": "tripadvisor",
          "profile_id": "xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx"
        }
      ], // Scrape profiles setup for the site
      "sectors": ["xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxxx"] // Sectors the site is allocated to
    }
  ]
}

Subscribe to all jobs for a company

Call this endpoint and based on your credentials you will be subscribed to all of the jobs that this company has. This will set you up to recieve all reviews which are made for this company via the review webhook.

URL

POST - https://depot-api.feeditback.com/company/company/{id}/subscribe

Request

INFO

No data is required to be passed in the body for this requested

Response

json
{
  "data": ["xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx"] // Array of Job Id's
}