For AI agents: a documentation index is available at the root level at /llms.txt and /llms-full.txt. Append /llms.txt to any URL for a page-level index, or .md for the markdown version of any page.
Log inBook a demo
GuidesAPI Reference
GuidesAPI Reference
  • API Reference
      • GETGet Enrichment Source
      • POSTEnrichment Fields
      • POSTPreview Model
      • GETList Models
      • POSTCreate Model
      • GETGet Model
      • PUTUpdate Model
      • DELDelete Model
      • GETSample Records
Logo
Log inBook a demo
API ReferenceModels

Sample Records

GET
https://app.polytomic.com/api/models/:id/sample
GET
/api/models/:id/sample
$curl https://app.polytomic.com/api/models/248df4b7-aa70-47b8-a036-33ac447e668d/sample \
> -H "X-Polytomic-Version: X-Polytomic-Version" \
> -u "<username>:<password>"
1{
2 "data": {
3 "records": [
4 {
5 "enricher-uuid": {
6 "name": "James"
7 },
8 "model-uuid": {
9 "name": "Jim"
10 }
11 }
12 ],
13 "warnings": [
14 "Enrichment failed for 4 records: you have ran out of credits"
15 ]
16 },
17 "job": {
18 "error": "error message",
19 "job_id": "248df4b7-aa70-47b8-a036-33ac447e668d",
20 "result": null,
21 "status": "created",
22 "type": "createmodel"
23 }
24}
Returns a sample of records from a model. Synchronous requests must complete within 10 seconds. If the source query or enrichment step can exceed that budget, use the asynchronous option so the work runs as a background job.
Was this page helpful?
Previous

Get Sync Source

Next

Authentication

AuthorizationBasic

This is the Polytomic deployment key (on-premises only)

OR
AuthorizationBearer
This is the Polytomic API key

Path parameters

idstringRequiredformat: "uuid"

Headers

X-Polytomic-VersionstringRequired

Query parameters

asyncbooleanOptional

Response

OK
dataobject
jobobject

Errors

400
Bad Request Error
401
Unauthorized Error
404
Not Found Error
500
Internal Server Error