SE DocsSE Docs
Developer

REST API

Use the versioned REST API to build custom integrations and automation workflows.

Shocking Energy provides a versioned REST API at /v1 for building custom integrations, dashboards, and automation workflows. The API uses JSON and standard HTTP conventions.


Base URL

https://api.jobway.ai/v1

For local development:

http://localhost:3003/v1

Authentication

All API requests require a Bearer token in the Authorization header:

curl https://api.jobway.ai/v1/jobs \
  -H "Authorization: Bearer YOUR_API_KEY"

Two token types are accepted:

Token typeFormatHow to obtain
API keyse_*Create in Settings > Developer > API Keys
OAuth tokense_oauth_*Via the OAuth flow

API documentation

Interactive API documentation (Swagger UI) is available at:

https://api.jobway.ai/v1/docs

The documentation is auto-generated from the API's OpenAPI specification and includes request/response schemas, parameter descriptions, and example values.


Endpoints overview

Jobs

MethodEndpointScopeDescription
GET/v1/jobsjobs.readList jobs with filters
GET/v1/jobs/:idjobs.readGet a specific job
POST/v1/jobsjobs.writeCreate a new job
POST/v1/jobs/:id/canceljobs.writeCancel a job
POST/v1/jobs/:id/assignjobs.writeAssign engineer
POST/v1/jobs/:id/startjobs.writeStart a job
POST/v1/jobs/:id/completejobs.writeComplete a job

Flows

MethodEndpointScopeDescription
GET/v1/flows/groupsflows.readList flow groups
GET/v1/flows/:idflows.readGet flow details
POST/v1/flows/:id/regenerateflows.writeRegenerate flow
POST/v1/flows/:id/resendflows.writeResend flow

Assets

MethodEndpointScopeDescription
GET/v1/assetsassets.readList assets with filters
GET/v1/assets/:idassets.readGet a specific asset
GET/v1/assets/filter-optionsassets.readGet filter metadata
GET/v1/assets/:id/historyassets.readList asset history
POST/v1/assetsassets.writeCreate asset
POST/v1/assets/:id/updateassets.writeUpdate asset
POST/v1/assets/:id/archiveassets.writeArchive asset
POST/v1/assets/:id/history/restoreassets.writeRestore asset snapshot

Projects

MethodEndpointScopeDescription
GET/v1/projectsprojects.readList projects
GET/v1/projects/:idprojects.readGet project details
GET/v1/project-templatesprojects.readList project templates
GET/v1/clientsprojects.readList clients
GET/v1/sitesprojects.readList sites
POST/v1/projectsprojects.writeCreate project
POST/v1/projects/revisions/createprojects.writeCreate revision
POST/v1/projects/jobs/addprojects.writeLink job to project
POST/v1/project-templatesprojects.writeCreate project template
POST/v1/clientsprojects.writeCreate client
POST/v1/sitesprojects.writeCreate site

Invoices

MethodEndpointScopeDescription
GET/v1/invoicesinvoices.readList invoices
GET/v1/invoices/:idinvoices.readGet invoice details
GET/v1/invoices/defaultsinvoices.readGet draft defaults
GET/v1/invoicing/profileinvoices.readGet invoicing profile
GET/v1/invoicing/contractsinvoices.readList contracts
GET/v1/invoicing/ratesinvoices.readList rates
POST/v1/invoices/draftinvoices.writeUpsert draft invoice
POST/v1/invoices/finalizeinvoices.writeFinalize invoice
POST/v1/invoices/approveinvoices.writeApprove invoice
POST/v1/invoicing/profile/upsertinvoices.writeUpsert invoicing profile
POST/v1/invoicing/contractsinvoices.writeCreate contract
POST/v1/invoicing/ratesinvoices.writeCreate rate
POST/v1/invoicing/template/upsertinvoices.writeUpsert invoice template

Team

MethodEndpointScopeDescription
GET/v1/teamteam.readGet team info
MethodEndpointScopeDescription
POST/v1/searchsearch.readSearch across team data

Metrics

MethodEndpointScopeDescription
GET/v1/metrics/jobsmetrics.readJob metrics
GET/v1/metrics/flowsmetrics.readFlow metrics

See the interactive API documentation for the complete list of endpoints, request parameters, and response schemas.


Request format

Query parameters

List endpoints support filtering via query parameters:

curl "https://api.jobway.ai/v1/jobs?status=PENDING&limit=10" \
  -H "Authorization: Bearer YOUR_API_KEY"

Request body

Write endpoints accept JSON request bodies:

curl -X POST https://api.jobway.ai/v1/jobs \
  -H "Authorization: Bearer YOUR_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{
    "jobTypeId": "123e4567-e89b-12d3-a456-426614174000",
    "scheduledDate": "2026-03-15",
    "notes": "Annual service visit"
  }'

Response format

Success responses

{
  "data": {
    "id": "123e4567-e89b-12d3-a456-426614174000",
    "status": "PENDING",
    "scheduledDate": "2026-03-15"
  }
}

List endpoints return an array:

{
  "data": [
    { "id": "...", "status": "PENDING" },
    { "id": "...", "status": "COMPLETED" }
  ]
}

Error responses

{
  "status": "error",
  "message": "Bad Request",
  "request_id": "req_abc123",
  "error": {
    "name": "BadRequestError",
    "issues": [
      {
        "message": "Invalid date format",
        "path": "scheduledDate"
      }
    ]
  }
}

HTTP status codes

CodeMeaning
200Success
201Created
400Bad request (validation error)
401Unauthorized (invalid or missing token)
403Forbidden (insufficient scope)
404Not found
429Rate limited
500Server error

Rate limiting

API requests are rate-limited to protect the service. When you exceed the limit, you receive a 429 response. Back off and retry after the time indicated in the Retry-After header.


MCP vs REST API

Both the MCP endpoint and REST API provide access to the same team data. Choose based on your use case:

FeatureMCP (/mcp)REST API (/v1)
ProtocolMCP (JSON-RPC over HTTP)REST (standard HTTP)
Best forAI assistants (Claude, Cursor)Custom integrations, scripts
ToolsDiscoverable via tools/listFixed endpoints
ResourcesStatic data via resources/readStandard GET endpoints
PromptsAnalysis templates via prompts/getNot available
AuthAPI key or OAuthAPI key or OAuth
ScopesSame scope systemSame scope system

Both use the same authentication and scope system. An API key works for both MCP and REST API access.

On this page