Skip to content
Last updated

Additional Search and Report Options

Overview

This document describes optional endpoints that complement the core company search and report workflow.

These endpoints provide additional functionality for:

  • Retrieving country-specific report schemas
  • Checking available report languages before requesting a report

Company Report Response Schemas

This endpoint retrieves the response schema for a company report in a specific country. It provides a detailed breakdown of the property structure for reports from that country.

Use this endpoint to:

  • Understand report structure before requesting data
  • Validate expected response fields
  • Map report data to your system
  • Support developer onboarding

Endpoint

GET /companies/schema/{countryCode}

Path Parameters

ParameterTypeDescription
countryCodestringISO2 country code (e.g., GB, US, DE)

Query Parameters

ParameterTypeRequiredDescription
sectionstringYesSection to retrieve, for example CompanyReportResponse

Example Request

GET /companies/schema/US?section=CompanyReportResponse
Authorization: Bearer <token>

Example Response

The response is a list of JSON Schema (draft-04) documents. The first describes the report response, and the others describe the types it uses, such as MessageCode and Language. This is a shortened US response:

[
  {
    "title": "CompanyReportResponse",
    "$schema": "http://json-schema.org/draft-04/schema#",
    "type": "object",
    "properties": {
      "chargeReference": { "type": "string" },
      "report": {
        "type": "object",
        "properties": {
          "companyId": { "type": "string" },
          "language": { "type": "language", "required": "true" }
        }
      }
    }
  },
  {
    "title": "MessageCode",
    "$schema": "http://json-schema.org/draft-04/schema#",
    "enum": ["NoResults", "ReportUnavailable"]
  }
]

Common Errors

StatusCause
200A section that isn't found returns 200 with an error body instead of a list: {"correlationId": "…", "message": "Bad Request", "details": "Schema not found…"}. Check that the response is a list before you use it
400The country isn't supported, for example "details": "SE is not a supported country"
401Invalid or expired authentication token

Available Company Report Languages

This endpoint retrieves the available report languages for a specific country. Use this to determine which language options are supported before requesting a company report.

Endpoint

GET /access/countries/{countryCode}/reportLanguages

Path Parameters

ParameterTypeDescription
countryCodestringISO2 country code (e.g., GB, US, BR)

Example Request

GET /access/countries/FR/reportLanguages
Authorization: Bearer <token>

Example Response

{
  "reportLanguages": [
    "EN",
    "FR"
  ],
  "correlationId": "e90e0934-06d9-4cf8-94a5-8e1fa568bd02"
}

EN is listed for every country, with the local language where there is one. For example, GB returns ["EN"] and SE returns ["EN", "SV"]. The country code isn't case sensitive.

The list doesn't say which language a report uses when you don't send language. Reports default to English (en), except BR reports, which default to Portuguese (pt), although EN is listed first. Send language=en for an English BR report.

Response Fields

FieldTypeDescription
reportLanguagesstring[]Array of available language codes for reports in this country
correlationIdstringUnique identifier for support tracking

Common Errors

StatusCause
400The country code isn't valid, or your account has no reports for the country: {"correlationId": "…", "message": "Bad Request", "details": "No access"}
401Invalid or expired authentication token
404Country not found or not supported

Usage Guidance

When to Use Report Schemas

Check the report schema when:

  • Integrating with the API for the first time
  • Building data mapping for a new country
  • Validating response structure in automated tests
  • Documenting expected fields for downstream systems

When to Use Report Languages

Check available languages when:

  • Building a multi-language user interface
  • Supporting international users
  • Determining default language for report requests
  • Validating language parameter before requesting reports

ResourceDescription
Company Search and Report WorkflowCore workflow for searching companies and retrieving reports
AuthenticationHow to authenticate with the API
Error CodesComplete error code reference