WWebToolSolutions
Registrati

Documentazione API

API REST di WebToolSolutions — per i piani Pro e Illimitato.

Autenticazione

Includi la tua chiave API come header in ogni richiesta:

X-API-Key: wts_live_xxxxxxxxxxxxxxxxxxxx

Crea le chiavi da: /dashboard/api-keys

URL base

https://api.webtoolsolutions.org/v1

Elenco moduli

GET /v1/modules

curl -H "X-API-Key: wts_live_..." \
  https://api.webtoolsolutions.org/v1/modules

Avvia un lavoro (upload file)

POST /v1/modules/{moduleId}/process

curl -H "X-API-Key: wts_live_..." \
  -F "file=@document.pdf" \
  -F "preserve_formatting=true" \
  https://api.webtoolsolutions.org/v1/modules/pdf-to-word/process

# Response:
{
  "success": true,
  "data": {
    "jobId": "job_01HXYZ...",
    "status": "PENDING",
    "pollUrl": "/v1/jobs/job_01HXYZ..."
  }
}

Verifica stato lavoro

GET /v1/jobs/{jobId}

curl -H "X-API-Key: wts_live_..." \
  https://api.webtoolsolutions.org/v1/jobs/job_01HXYZ...

# When completed:
{
  "success": true,
  "data": {
    "jobId": "...",
    "status": "COMPLETED",
    "progress": 100,
    "result": {
      "downloadUrl": "https://cdn.webtoolsolutions.org/...",
      "filename": "document.docx",
      "fileSizeBytes": 245760,
      "expiresAt": "..."
    }
  }
}

Avanzamento in tempo reale via WebSocket

ws://api.webtoolsolutions.org/v1/ws?jobId=job_01HXYZ...

// Message types:
{ "type": "progress", "percent": 65, "message": "Converting pages..." }
{ "type": "completed", "result": {...} }
{ "type": "failed", "error": {...} }

Webhook

Quando un lavoro è completato o fallisce, facciamo POST sul tuo URL registrato.

POST {your_webhook_url}
X-WTS-Signature: sha256=...
X-WTS-Event: job.completed

{
  "event": "job.completed",
  "jobId": "...",
  "result": {...},
  "timestamp": "..."
}

Gestiscili in Account → Webhook.

Codici di errore

  • 401 AUTH_REQUIRED
  • 402 PLAN_REQUIRED
  • 413 FILE_TOO_LARGE
  • 415 FILE_TYPE_INVALID
  • 422 VALIDATION_ERROR
  • 429 QUOTA_EXCEEDED / RATE_LIMIT_EXCEEDED

Limite di richieste

  • Pro: 600 req/min · 200 jobs/day
  • Unlimited: 1200 req/min · unlimited jobs