Skip to content

Documentation · API reference

API reference

Every public endpoint, its parameters and an example request.

POST/v1/images/searchScope: search

Starts a job and returns 202 straight away. Send either query (with an optional count) or a queries array for a batch.

FieldTypeDescription
querystringThe search text, up to 200 characters.
countstringImages wanted per query, as a positive decimal string. Default "15". No product cap; the source may have fewer.
queriesarrayA batch of { query, count } objects. Queries must be unique.
min_widthintegerMinimum width in pixels, 0 to 20000. Default 800.
exclude_domainsstring[]Plain domains to skip, such as example.com.
watermark_policystringprefer_clean (default) or any. A hint from titles and domains, not a guarantee.
safe_search, image_type, layout, size, colorstringOptional filters.
Request
curl -X POST "$PLUKO_URL/v1/images/search" \
  -H "Authorization: Bearer $PLUKO_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{
  "query": "concrete architecture",
  "count": "15",
  "min_width": 1000
}'
Response · 202
{
  "job_id": "job_example",
  "reused": false,
  "status_url": "/v1/jobs/job_example",
  "results_url": "/v1/jobs/job_example/results",
  "request_id": "req_example"
}

Get a job

GET/v1/jobs/{job_id}Scope: read

Returns the job’s status, per-query progress, the filters it ran with, and expires: when its results will be removed.

Request
curl "$PLUKO_URL/v1/jobs/JOB_ID" \
  -H "Authorization: Bearer $PLUKO_API_KEY"
Response · 200 (excerpt)
{
  "job": {
    "id": "job_example",
    "status": "running",
    "requested": "15",
    "returned": 6
  },
  "request_id": "req_example"
}

Read results

GET/v1/jobs/{job_id}/resultsScope: read
FieldTypeDescription
limitinteger1 to 100. Default 50.
afterintegerCursor from the previous page’s next_cursor, or poll_after while the job runs. Default 0.
Request
curl "$PLUKO_URL/v1/jobs/JOB_ID/results?limit=100&after=0" \
  -H "Authorization: Bearer $PLUKO_API_KEY"
Response · 200 (excerpt)
{
  "images": [
    {
      "id": "img_example",
      "title": "Concrete architecture",
      "image_url": "https://source.example/image.jpg",
      "thumbnail_url": "https://source.example/preview.jpg",
      "source_url": "https://source.example/photo",
      "width": 1600,
      "height": 1200,
      "dimensions_verified": false,
      "license_status": "unknown"
    }
  ],
  "next_cursor": null,
  "request_id": "req_example"
}

List jobs

GET/v1/jobsScope: read

Lists the key’s project jobs, newest first.

FieldTypeDescription
limitinteger1 to 100. Default 50.
statusstringqueued, running, complete, partial or cancelled.
beforeintegerPass next_cursor from the previous page.
Request
curl "$PLUKO_URL/v1/jobs?status=running" \
  -H "Authorization: Bearer $PLUKO_API_KEY"

Cancel and retry

POST/v1/jobs/{job_id}/cancelScope: search
POST/v1/jobs/{job_id}/retryScope: search

Cancel stops a queued or running job. A job that already finished returns 409 JOB_FINISHED and keeps its status. Retry creates a new job from the original request and returns its job_id.

Request
curl -X POST "$PLUKO_URL/v1/jobs/JOB_ID/cancel" \
  -H "Authorization: Bearer $PLUKO_API_KEY"

Send feedback

POST/v1/feedbackScope: search
FieldTypeDescription
job_idrequiredstringThe job the result belongs to.
result_idrequiredstringThe image’s id.
reasonrequiredstringnot_relevant, watermark, broken or other.
notestringUp to 1000 characters.
Request
curl -X POST "$PLUKO_URL/v1/feedback" \
  -H "Authorization: Bearer $PLUKO_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{
  "job_id": "JOB_ID",
  "result_id": "IMAGE_ID",
  "reason": "not_relevant",
  "note": "The result does not match the query."
}'

List your reports, newest first, with GET /v1/feedback (read scope). Each one includes an image with its title, URLs and source domain, or null once retention has removed the result.

Usage

GET/v1/usageScope: read

Today’s provider pages used, the project’s daily limit, pages remaining, when it resets (00:00 UTC) and the last week. A page is one request to the image source and returns up to 35 images.

Request
curl "$PLUKO_URL/v1/usage" \
  -H "Authorization: Bearer $PLUKO_API_KEY"

Service status

GET/v1/statusNo API key needed

Reports whether the API, the search worker and the image source are working. It needs no key and is also shown on the status page.

Request
curl "$PLUKO_URL/v1/status"

Was this page helpful?

Tell us what’s missing. We read every note.