Perception
Add a schema version
- Earlier versions stay as they were, so an extract that names schema_version keeps getting the same schema.
- `name` and `description`, when left out, carry over from the previous version.
- Earlier versions stay as they were, so an extract that names
schema_versionkeeps getting the same schema. nameanddescription, when left out, carry over from the previous version.
Other errors (413, 500, 502, 503) are on Errors.
Authorization
bearerAuth AuthorizationBearer <token>
Your API key, sent as Authorization: Bearer nace_sk_...
- Where: the dashboard's API Keys page. It is shown once, when you create it.
- Format:
nace_sk_followed by 43 URL-safe characters (A-Z,a-z,0-9,_and-). - Limit: an account can hold at most 3 active keys.
- Wrong or missing key: returns
401 authentication_error.
In: header
Path Parameters
idstringrequired
The schema's schema_id (sch_...). An id longer than 128 characters answers 404 with code not_found, not schema_not_found.
Length
length <= 128Request Body
application/json
namestring
Length
1 <= length <= 128descriptionstring
Length
1 <= length <= 2000schemaobjectrequired
The new version's JSON Schema.
Show child attributes
Response Body
application/json
application/json
application/json
application/json
application/json
curl -X POST "https://example.com/v1/extraction-schemas/string/versions" \ -H "Content-Type: application/json" \ -d '{ "description": "Invoice header fields and due date", "schema": { "type": "object", "properties": { "invoice_number": { "type": "string" }, "total": { "type": "number" }, "due_date": { "type": "string", "description": "The due date, as YYYY-MM-DD" } } } }'{ "schema_id": "string", "name": "string", "description": "string", "version": 1, "owner": "account", "created_at": "2019-08-24T14:15:22Z", "updated_at": "2019-08-24T14:15:22Z", "schema": {}}