Referência da APITemplates
Get a template
GET
A template whose endpoint can run now, as GET /v1/templates lists it.
ApiKeyAuthheader
X-Api-Key<token>id*stringThe template's id, such as amazon-price-tracking
Length
1 <= lengthTemplate
application/json- response
id*stringname*stringdescription*stringcategory*stringendpoint*mapping*Per endpoint parameter, the input column it takes ({"column": …}) or a fixed value ({"value": …})
sample_columns*array<string>The columns the mapping reads, as in the example file
sample_rows*array<>schedule*|The suggested schedule; null: runs only when asked
alert_events*array<>What the alert channels chosen at creation subscribe to
tracked_fields*array<string>output_formats*array<>rate_percent*integercurl -X GET 'https://dataflow.piloterr.com/v1/templates/string'Example Response
{
"id": "amazon-price-tracking",
"name": "Track Amazon prices and stock",
"description": "Price, stock and coupon of each product (ASIN) every day, with an alert when one changes.",
"category": "monitoring",
"endpoint": {
"id": "cm0p7x3da000a08l4gs5e2n1c",
"name": "Amazon Product",
"path": "/v2/amazon/product",
"credit_cost": 1,
"billing_mode": "per_call"
},
"mapping": {
"query": {
"column": "asin"
},
"domain": {
"column": "marketplace"
}
},
"sample_columns": [
"asin",
"marketplace"
],
"sample_rows": [
{
"asin": "B0CSF8ZGB4",
"marketplace": "com"
},
{
"asin": "B08N5WRWNW",
"marketplace": "com"
},
{
"asin": "B07PGL2ZSL",
"marketplace": "fr"
}
],
"schedule": {
"interval": "daily",
"cron": null,
"timezone": "UTC"
},
"alert_events": [
"run.failed",
"run.paused",
"run.error_rate_exceeded",
"credits.insufficient",
"project.auto_disabled",
"source.unreachable",
"run.changes_detected"
],
"tracked_fields": [
"price",
"stock",
"coupon"
],
"output_formats": [
"json"
],
"rate_percent": 30
}