# Getting started

Search official Chinese government publications in English and Chinese.

The ReConnect China API gives partner organizations scripted access to the corpus behind
[reconnectchina.org](https://reconnectchina.org): official publications from central,
ministry, provincial and local government websites in China, with English titles and
summaries.

## What these pages are

These pages are the reference for the API, and a console for it. Every operation has a page of
its own, with its parameters as a form: fill it in, run the request once you are logged in, and
copy it as Python, curl or Node. Read them in order, with the links at the foot of each page,
and you will have seen all of the API.

If you would rather start from code, the [examples](/docs/examples.md) are complete programs that
each do one job, such as writing a search's results to a CSV file. Download one, run it, and
come back here for whatever you want to change.

## Where to start

Reading these pages needs no account. Running a request from them needs a reconnectchina.org
account: [Logging in](/docs/login.md). A script logs in with a token of its own:
[Creating a token for a script](/docs/login/script-token.md). To call the API from Python or Node,
install a client library: [Client libraries](/docs/clients.md).

Registering an account is an application, which we review. Once your account is in an
organization the API answers it, the sandbox first. Until then every request is refused with
`403` and the problem type [`no-organization`](/docs/v1/problems/no-organization.md), although you
can log in. We warmly recommend turning on two-factor authentication for your account at
account.reconnectchina.org. It is optional, and it keeps a stolen password from being enough.

1. [Using the API](/docs/v1.md) covers what holds for every request: access belongs to your
   organization, the sandbox, paging, errors and what stays compatible.
2. [Search](/docs/v1/search.md) is where most scripts begin. The contents list every other
   operation.
3. [Term expressions](/docs/v1/terms.md) and [Instant expressions](/docs/v1/instants.md) describe the
   two small languages a search is written in, and [Dates and time zones](/docs/v1/dates.md) which
   dates a search filters on, how to show them, and in which time zone to count.

## In other formats

The API is described by an OpenAPI document. Every API host publishes it beside these pages, at
[/docs/v1/openapi.json](/docs/v1/openapi.json).

Every page is also there as Markdown, for a program or an AI agent to read, or for you to keep:
add `.md` to its path, as in [/docs/v1/search.md](/docs/v1/search.md), or ask for the page itself
with the header `Accept: text/markdown`. It holds all of the page's text, an operation's inputs
and responses in full, and the samples. The link at the foot of every page opens it, and
[/llms.txt](/llms.txt) lists them all, in the order of these pages.
