From the command line

One command per operation a key can perform, ready to copy.

Contract version 1.15.0 The reference below is read from the OpenAPI contract, which is written in English. It is not translated on purpose: translating it would mean copying it, and a copy drifts. Download the public contract (OpenAPI, JSON)

There is nothing to install

There is no Postqron program to download, and this page is the reason you do not need one: the API speaks plain HTTP, so a shell and curl reach all of it. Nothing here wraps the API — it is the API.

The commands below are generated from the same contract as the REST reference, which is what makes them worth copying: each one names a route that exists, with the method it really wants.

Your key, and where to keep it

Create a key in the dashboard and give it only the scopes the script needs. Then keep it in the environment rather than in the command: a key typed inline is a key saved in the shell history, and history files get shared.

Set POSTQRON_API_KEY and every command on this page works unchanged. To act inside a workspace that is not your own, add the header X-Postqron-Workspace with the identifier of its owner.

List jobs (R8)jobs:read
curl \
  --header "Authorization: Bearer $POSTQRON_API_KEY" \
  'https://api.postqron.com/jobs'

One command per operation

These are the operations a key can perform. Anything in braces is yours to replace; where a body is expected, the file name is the schema the contract asks for, and the contract is where its fields are described.

List jobs (R8)jobs:read
curl \
  --header "Authorization: Bearer $POSTQRON_API_KEY" \
  'https://api.postqron.com/jobs'
Create a job (R1, R8)jobs:write
curl \
  --request POST \
  --header "Authorization: Bearer $POSTQRON_API_KEY" \
  --header 'Content-Type: application/json' \
  --data @job-input.json \
  'https://api.postqron.com/jobs'
Read one jobjobs:read
curl \
  --header "Authorization: Bearer $POSTQRON_API_KEY" \
  'https://api.postqron.com/jobs/{id}'
Partially update a jobjobs:write
curl \
  --request PATCH \
  --header "Authorization: Bearer $POSTQRON_API_KEY" \
  --header 'Content-Type: application/json' \
  --data @job-input.json \
  'https://api.postqron.com/jobs/{id}'
Delete a jobjobs:write
curl \
  --request DELETE \
  --header "Authorization: Bearer $POSTQRON_API_KEY" \
  'https://api.postqron.com/jobs/{id}'
Execution log (R6)executions:read
curl \
  --header "Authorization: Bearer $POSTQRON_API_KEY" \
  'https://api.postqron.com/jobs/{id}/executions'
Run now (R8)executions:trigger
curl \
  --request POST \
  --header "Authorization: Bearer $POSTQRON_API_KEY" \
  --header 'Content-Type: application/json' \
  --data @trigger-input.json \
  'https://api.postqron.com/jobs/{id}/executions'
Execution log in real time (SPEC §4.2)executions:read
curl \
  --header "Authorization: Bearer $POSTQRON_API_KEY" \
  'https://api.postqron.com/jobs/{id}/executions/stream'
Download the execution log (R27)executions:read
curl \
  --header "Authorization: Bearer $POSTQRON_API_KEY" \
  'https://api.postqron.com/executions/export'
Duration, failure rate and trend (R28)executions:read
curl \
  --header "Authorization: Bearer $POSTQRON_API_KEY" \
  'https://api.postqron.com/executions/metrics'
List workspace secrets (R42)secrets:read
curl \
  --header "Authorization: Bearer $POSTQRON_API_KEY" \
  'https://api.postqron.com/secrets'