Skip to main content

Developers

API quickstart

Prepare a filing with the FileClerk API and receive its final status through a signed webhook.

Last updated 23 November 2026

Use your API key with a draft and audit exemption answers from the OpenAPI schema.

TypeScript dry run
export async function prepareAccounts(
  draft: object,
  eligibility: object,
  apiKey: string,
  idempotencyKey: string,
  origin = "https://fileclerk.co.uk",
  request: (url: string, init?: RequestInit) => Promise<Response> = fetch,
) {
  const response = await request(origin + "/api/v1/filings/accounts", {
    method: "POST",
    headers: {
      "content-type": "application/json",
      "x-api-key": apiKey,
      "idempotency-key": idempotencyKey,
    },
    body: JSON.stringify({ dry_run: true, draft, eligibility }),
  })
  if (!response.ok) throw new Error(`Accounts preparation returned HTTP ${response.status}`)
  return response.json()
}

Use the calculated totals and individual findings to check the draft. When ready is true, the response includes checked iXBRL. The API currently supports preparation and signed receipts.

Reuse the same idempotency key for retries of the same draft. For 24 hours, a changed payload using that key receives HTTP 409.

Filing webhooks

Once a submitted filing reaches a final status, FileClerk can send a signed filing.updated event to the submitter’s confirmed JSON webhook for that company. The payload contains the filing identifier, company number, previous and current status, and the time FileClerk observed the change.

Verify the Standard Webhooks signature before using the event. Deduplicate retries using thewebhook-id header.