Schema

Scalars

Enums

Objects

Input Objects

Third-party access

A third party calls the API on behalf of a broker with a token the broker issued (or approved through Connect). Send it as Authorization: Bearer <token> in a POST to /third-party/graphql on the API host, with a JSON body {"query": …, "variables": …, "operationName": …}. The token acts as the broker who issued it and can call only the operations granted to your system, chosen from the list below. Introspection (__schema, __type), subscriptions and every other field are refused; __typename is allowed.

Rules

  • One query or mutation per request; no batches.
  • Every root field must be an operation your token is granted, including fields reached through fragments.
  • Documents may nest at most 10 fields deep, with a complexity of at most 500.
  • Every permitted request counts as one use of the token, even if it then fails. A single-use token is spent by its first permitted request; refused and rate-limited requests do not spend it.
  • Each token has a per-minute and a per-day limit, set by the strictest operation in the request (see the table below). Going over gets a 429; the token is not revoked.

Errors

HTTP statusextensions.codeMeaning
403FORBIDDENThe request calls an operation the token is not granted (listed in extensions.operations), introspection, a subscription, more than one operation, or nests too deep. Nothing ran and no use was spent.
401TOKEN_SPENTThe token has been used up, has expired or has been revoked.
429RATE_LIMITEDOver the token's per-minute or per-day limit. Retry after the number of seconds in the Retry-After header (also extensions.retryAfter).
403(gateway)The token is not valid: wrong signature, expired, revoked, the third party is suspended, or the broker's firm can no longer use it.

Operations

caseResults (query, reads: 60 a minute, 2000 a day per token)

Returns the current case results for a specific case. Company admins and broker managers can read every case in their company.

query { caseResults(   # The unique identifier of the case.
uuid: String! ): [CaseResult!]! }

cases (query, reads: 60 a minute, 2000 a day per token)

Returns a list of cases for the authenticated user. For company admins and broker managers, returns every case in their company.

query { cases(   # Maximum number of cases to return.
limit: Int = 20   # Number of cases to skip.
offset: Int = 0 ): [Case!] }

search (query, reads: 60 a minute, 2000 a day per token)

Search cases with pagination. Searches across case UUID, client names and reference. Company admins and broker managers search every case in their company.

query { search(   # Maximum number of cases to return.
limit: Int = 20   # Number of cases to skip.
offset: Int = 0   # Search term to match against case UUID, client names, or reference.
query: String! ): PaginatedCases! }

searchAdvisers (query, reads: 60 a minute, 2000 a day per token)

Search the advisers in the caller's company, ordered alphabetically by first name, then surname. Only company admins and broker managers can call it.

query { searchAdvisers(   # Maximum number of advisers to return (at most 200).
limit: Int = 50   # Case-insensitive exact match on the adviser's office (site) name.
office: String   # Number of advisers to skip.
offset: Int = 0   # Case-insensitive search against the adviser's first name, surname, full name or email.
query: String ): PaginatedAdvisers! }

createBtlCase (mutation, results: 10 a minute, 200 a day per token)

Creates a buy-to-let, BTL, case to run the affordability results for.

mutation { createBtlCase(   # The unique identifier of the adviser the case is created for. Required, and must be an adviser in the company, while impersonating a company.
advisorUuid: String   # The applicants for the case.
applicants: [BtlApplicant!]!   # The loan details for the case.
loan: BtlLoan!   # The personal details for the case.
personalDetails: BtlPersonalDetails!   # The properties owned/mortgaged by the applicants.
properties: [BtlProperty!]!   # The property cost details for the case.
propertyCost: BtlPropertyCost! ): Case! }

createBtlCaseDraft (mutation, drafts: 30 a minute, 500 a day per token)

Creates a draft buy-to-let, BTL, case to run the affordability results lazily.

mutation { createBtlCaseDraft(   # The unique identifier of the adviser the case is created for. Required, and must be an adviser in the company, while impersonating a company.
advisorUuid: String   # The applicants for the draft case.
applicants: [BtlApplicantDraft!]   # The loan details for the draft case.
loan: BtlLoanDraft   # The personal details for the draft case.
personalDetails: BtlPersonalDetailsDraft   # The properties owned/mortgaged by the applicants.
properties: [BtlProperty!]   # The property cost details for the draft case.
propertyCost: BtlPropertyCostDraft ): Case! }

createCase (mutation, results: 10 a minute, 200 a day per token)

Creates a residential case to run the affordability results for.

mutation { createCase(   # The unique identifier of the adviser the case is created for. Required, and must be an adviser in the company, while impersonating a company.
advisorUuid: String   # The applicants for the case.
applicants: [Applicant!]!   # The loan details for the case.
loan: Loan!   # The mortgage product preferences for the case.
preference: Preference   # The background properties for the case (Resi or BTL, or unencumbered).
properties: [Property!]! ): Case! }

createCaseDraft (mutation, drafts: 30 a minute, 500 a day per token)

Creates a draft residential case to run the affordability results lazily.

mutation { createCaseDraft(   # The unique identifier of the adviser the case is created for. Required, and must be an adviser in the company, while impersonating a company.
advisorUuid: String   # The applicants for the draft case.
applicants: [ApplicantDraft!]   # The loan details for the draft case.
loan: LoanDraft   # The mortgage product preferences for the draft case.
preference: Preference   # The properties for the draft case.
properties: [Property!] ): Case! }

invokeCaseResults (mutation, results: 10 a minute, 200 a day per token)

Evaluates the results of the case. Accepts both residential and buy to let cases. Check `case_results` subscription for listening to the results as they arrive.

mutation { invokeCaseResults(   # Unique identifier of the case to invoke the result calculations on.
caseUuid: String! ): Case! }

updateBtlCaseDraft (mutation, drafts: 30 a minute, 500 a day per token)

Updates details of a buy-to-let, or BTL, draft case.

mutation { updateBtlCaseDraft(   # The applicants for the draft case.
applicants: [BtlApplicantDraft!]   # The loan details for the draft case.
loan: BtlLoanDraft   # The personal details for the draft case.
personalDetails: BtlPersonalDetailsDraft   # The properties owned/mortgaged by the applicants.
properties: [BtlProperty!]   # The property cost details for the draft case.
propertyCost: BtlPropertyCostDraft   # The unique identifier of the draft case to be updated.
uuid: String! ): Case! }

updateCaseDraft (mutation, drafts: 30 a minute, 500 a day per token)

Updates details of a residential draft case.

mutation { updateCaseDraft(   # The applicants for the draft case.
applicants: [ApplicantDraft!]   # The loan details for the draft case.
loan: LoanDraft   # The mortgage product preferences for the draft case.
preference: Preference   # The properties for the draft case.
properties: [Property!]   # The unique identifier of the draft case to be updated.
uuid: String! ): Case! }