China Company Annual Reports API in n8n
Configure an n8n HTTP Request node to retrieve annual report records for a Chinese company and handle the available filing fields.
Retrieve annual report records and available filing details for a company.

Set up an n8n workflow that takes the full Chinese legal name of a company, calls ChinaValidate's annual reports endpoint and reads the available filing records. Start with a Manual Trigger and an Edit Fields node carrying one known company name. Connect an HTTP Request node for the API call, followed by a step that handles the result. The first version should make one request when you run it and preserve its original response while you verify the mapping.
Company annual reports are grouped by filing records, with the reporting year and date where available. This guide shows how to connect those fields to an n8n workflow. The reporting year belongs to the filing. It is distinct from the date of publication or the date your workflow downloaded it. Keep those values separate when you store the result. Annual Reports API reference
Set the company input
Add a Manual Trigger and connect an Edit Fields node. Create a field named company_name and put in the complete Chinese registered name from an authorized company record. Give the item one input object. The HTTP node will use that name in a query parameter. The manual trigger is convenient while adding credentials and verifying the shape of one company response. It also helps avoid a request for every row of an imported list while you are still setting up the workflow.
If your source system only has the Unified Social Credit Code, resolve it through the company profile operation first. Use the returned Chinese legal name from the original data to call the annual reports operation. Confirm that the code belongs to the intended company before using the result. The annual-report request in this guide expects the full Chinese name. A translated display name from the company profile is useful to staff but should not be substituted for that request input. Company Profile API
Before you enable a scheduled or automated trigger, decide where that legal name is expected to come from. Save the company code in your own system if available and keep the latest verified Chinese name beside it. For this walkthrough, use one legitimate company identity and your own authorized key. Example responses in the documentation are suitable for testing later workflow steps without calling the API.
Configure the HTTP Request node
Choose GET and set the URL to https://api.chinavalidate.com/v1/companies/annual-reports. In n8n's HTTP Request node, under Authentication use a generic header credential for the Authorization header and store the value as Bearer followed by your API key. Keep the key in the credential field rather than embedding it in expressions, sample workflow JSON or shared screenshots. Use the HTTP node's query parameters section so n8n handles URL encoding. n8n HTTP Request node
| HTTP node setting | Value |
|---|---|
| Method | GET |
| Query parameter company_name | Expression reading the company_name field from the incoming item |
| Query parameter language | zh-CN for the original Chinese response |
| Header credential name | Authorization |
| Response format | JSON for this example |
Enter the following n8n expression in the query value in Expression mode. Check its preview to confirm it shows the full Chinese name from the item. The API key remains in the credential. Look at the final request settings to make sure the URL, query parameter names and language agree with the API reference. Ensure the workflow has one incoming item for this first test.
{{ $json.company_name }}
Use the normal JSON body output for the code example below. If you enable the option to include headers and the HTTP status, the response body will be wrapped with that extra information. Adapt the expression or code to read the body in that configuration. The provider request identifier, when present, can be useful for follow-up and usage reconciliation. Save it only if you actually choose the header-inclusive output and extract it.
Handle the response as a filing list
The HTTP Request node can receive HTTP 200 even when the API application code reports an error. Inspect the envelope before the rest of the workflow handles report data. Add a Code node after the HTTP Request node, choose Run Once for Each Item, and use this example with the normal JSON response configuration. It returns a single object containing a simple list for the next node. Saved data and identifiers can then be handled by a storage step that fits your application.
const reply = $json;
if (reply.code !== 200) {
return { json: { lookup_status: "api_error", api_code: reply.code ?? null } };
}
if (!Array.isArray(reply.data?.items)) {
throw new Error("Expected data.items to be an array");
}
const reports = reply.data.items.map((record) => ({
report_year: record.report_year ?? null,
report_date: record.report_date ?? null,
report_details: record.report_details ?? null,
}));
return {
json: {
lookup_status: reports.length ? "reports_returned" : "no_reports_returned",
total_count: reply.data.total_count,
reports,
},
};
The new lookup status belongs to your own workflow. It records how this execution interpreted the provider response. It is not a field received from ChinaValidate. A zero-result response can remain in the workflow as a completed lookup without filing rows. A non-success application code can be routed separately. A connection or parsing error in the earlier HTTP step needs its own workflow error handling. Test those paths independently, since a failure to receive a valid response cannot tell you whether reports are available.
Store years and dates as separate values
In the public example, a filing for reporting year 2024 can have a report date in 2025. Retain both fields when you build a storage record. A prior report should still be readable after a newer year arrives. If you track retrieval time, use a separate value set by your workflow. That gives the record three distinct times where values are available. Use the available company identifier, observed year and your own record key for company history, leaving room for a later corrected filing.
Keep the nested details if another system needs them. A dashboard can display just the report year and date while an analyst has access to the detailed values. An omitted detail should remain unavailable. Avoid replacing a missing value with zero in a report view. If you use a translated response, keep the original fields for comparisons and any follow-up request that requires the Chinese name. ChinaValidate OpenAPI response examples
Suppose a workflow returns two filings and one lacks the details needed for an internal decision. Keep both records and reveal the gap for the older or incomplete one. The workflow can say that the service returned a filing for that year while leaving missing facts open. This provides a usable results list even when some fields in a particular company report are unavailable.
Start with one execution
Run the workflow with one input and check that the HTTP Request node made the expected call. Confirm that the query passed the full Chinese name and that the workflow identified the returned years correctly. Then try the downstream Code node against a saved no-result response and a documented application error. Those fixture checks verify the branching without spending more credits. The first live lookup can be enough to verify the credential and connection. ChinaValidate API pricing
When the workflow takes data from a form, sheet or schedule, the number of input items affects the number of requests. Estimate the number of records you will send on a run and prevent repeated tests from submitting an entire production list. The API consumption can include ordinary empty responses. Before adding automatic retries, understand how usage is recorded and how a client-side timeout can leave completion uncertain. Record the workflow execution ID and any provider request reference you have.
Give the workflow a clear output contract before other teams use it. The next node needs to distinguish a success with available reports, a success without them and a response that needs operator attention. Write down which node supplies the input name and which credential owns the call. Then confirm that a report's own year and date remain visible after the result is saved. Those simple distinctions make the n8n integration useful in a real data pipeline.
Add an output step after verifying the mapping
For a first storage test, write the compact result to an internal dataset using a stable company reference from the input. In n8n, the HTTP Request output can replace the fields that were on the incoming item. If your downstream node needs the original credit code or record ID, read it from the named input step for the same execution or merge the relevant input explicitly. Verify the behavior with one item before passing more than one company. A result that has been saved under the wrong legal identity is difficult to correct by looking only at the retrieval date.
Check how the downstream system treats a later empty response. It can record that an execution returned no reports while keeping previously obtained records with their original dates. Success with a revised filing can create a different historical record. An error state should be visible to the person responsible for the workflow, with enough context to identify the failing node, the company input and the outcome without exposing the API key.