Skip to main content
UnaGo - AI Operations PlatformUnaGo
Developer documentation

Integrate your platform with UnaGo

A practical REST API reference for secure authentication, structured data, tasks, personal automations, and file storage—with copy-ready request and response examples.

Quick start

Make your first authenticated request

Use the base URL assigned to your environment. The examples below use environment variables so credentials never appear in source code.

1

1. Set the base URL

Store the environment origin, such as https://devm.hyperionwave.com, in BASE_URL.

2

2. Obtain a JWT

Authenticate with Security API, then keep the access token in a secure runtime variable.

3

3. Call a service

Add the service prefix, send JSON or multipart data, and handle every non-2xx status explicitly.

API catalog

Supported integration services

Each service has a versioned base path, endpoint summary, and representative payloads below.

Authentication

Issue and refresh access tokens, close sessions, and retrieve the current profile.

/security-api/api/v1/auth

Data Management

Define tables, store and query records, manage datasets, views, and record-triggered automations.

/data-api/api/v1

Tasks

Create work, update lifecycle state, read results, and collaborate through comments and TODOs.

/tasks-api/api/v1

Personal Automations

Create user-owned schedules, update automation settings, and trigger an immediate run.

/tasks-api/api/v1/automations

Storage API v2

Upload, download, search, organize, share, and delete private or company files.

/storage-api/api/v2/storage

Security API

Authentication endpoints

Base path: /security-api/api/v1/auth

Send the access token on protected requests as Authorization: Bearer <JWT>. Keep access and refresh tokens out of logs, URLs, analytics events, and browser storage you do not control.

  • POST /login — authenticate with local credentials or a supported identity provider
  • POST /refresh — exchange a refresh token for a current token pair
  • POST /logout — close the active session
  • GET /profile — retrieve the authenticated user's profile
  • POST /validate — validate a JWT in a trusted service integration

Payload example

Login and refresh tokens

Login request

POST /security-api/api/v1/auth/login

{
  "provider": "local",
  "email": "developer@example.com",
  "password": "<password>"
}

Login response

{
  "accessToken": "eyJ...",
  "refreshToken": "eyJ...",
  "tokenType": "Bearer",
  "expiresIn": 3600,
  "companyRequired": false,
  "user": {
    "id": "usr_4f8d2",
    "email": "developer@example.com",
    "name": "Alex Morgan",
    "companyId": "cmp_91ab",
    "roles": ["member"]
  }
}

Refresh request

POST /security-api/api/v1/auth/refresh

{
  "refreshToken": "eyJ..."
}

Data API

Tables, records, datasets, and views

Base path: /data-api/api/v1

Create a table schema before writing validated records. Query endpoints support structured filters, projections, sorting, full-text search, and offset pagination.

  • GET | POST /schemas — list or create table schemas
  • GET | PUT | DELETE /schemas/{table} — retrieve, replace, or remove a schema
  • GET /tables — list logical tables
  • PATCH | DELETE /tables/{table} — rename or delete a table
  • GET | POST /data — list or create records
  • POST /data/query — query records with filters, sorting, projection, search, limit, and offset
  • POST /data/batch — write multiple records
  • GET /data/stats — retrieve field and record statistics
  • PUT | DELETE /data/{id} — update or delete a record
  • GET | POST /datasets — list or store datasets
  • GET | DELETE /datasets/{id} — retrieve or delete a dataset
  • POST /datasets/{id}/query | /aggregate | /sample — analyze a dataset
  • GET | POST /views — list or create saved views
  • GET | PUT | DELETE /views/{viewId} — manage a saved view
  • GET | POST /automations — list or create record-triggered automations
  • GET | PUT | DELETE /automations/{automationId} — manage one record-triggered automation

Payload example

Create a table and store a record

Create a schema

POST /data-api/api/v1/schemas

{
  "table": "orders",
  "description": "Customer orders received from the commerce platform",
  "fields": [
    { "name": "customerId", "type": "string", "required": true },
    { "name": "amount", "type": "number", "required": true },
    {
      "name": "status",
      "type": "string",
      "required": true,
      "enum": ["open", "approved", "rejected"]
    }
  ]
}

Store a record

POST /data-api/api/v1/data

{
  "table": "orders",
  "data": {
    "customerId": "cus_8021",
    "amount": 249.95,
    "status": "open"
  },
  "metadata": {
    "source": "commerce-sync",
    "correlationId": "req_7b21"
  }
}

Store response

{
  "success": true,
  "table": "orders",
  "recordId": "67a2f98c41b6d2a71f003e12",
  "validated": true,
  "verified": true,
  "timestamp": "2026-08-11T09:30:00Z"
}

Payload example

Query records with filters and pagination

Query request

POST /data-api/api/v1/data/query

{
  "table": "orders",
  "filters": {
    "status": "open",
    "amount": { "$gte": 100 }
  },
  "projection": { "customerId": 1, "amount": 1, "status": 1 },
  "sort": { "amount": -1 },
  "limit": 25,
  "offset": 0
}

Query response

{
  "table": "orders",
  "records": [
    {
      "recordId": "67a2f98c41b6d2a71f003e12",
      "table": "orders",
      "data": {
        "customerId": "cus_8021",
        "amount": 249.95,
        "status": "open"
      },
      "version": 1,
      "createdAt": "2026-08-11T09:30:00Z"
    }
  ],
  "totalRecords": 1,
  "returnedRecords": 1,
  "hasMore": false
}

Tasks API

Task lifecycle and collaboration

Base path: /tasks-api/api/v1

Tasks are tenant-scoped units of work. Create a task, optionally assign an agent and TODOs, start it, track readiness, and read result history.

  • GET | POST /tasks — list or create tasks
  • GET | PUT | DELETE /tasks/{id} — retrieve, update, or delete a task
  • GET /tasks/stats — retrieve task status counts
  • POST /tasks/{id}/start — start a task
  • PUT /tasks/{id}/status — update status and optional result text
  • GET /tasks/{id}/ready — check dependency readiness
  • GET /tasks/{id}/results — retrieve result history
  • GET | POST /tasks/{id}/comments — list or add comments
  • PUT | DELETE /tasks/{id}/comments/{commentId} — update or delete a comment
  • GET | POST /tasks/{id}/todos — list or add TODOs
  • PUT | DELETE /tasks/{id}/todos/{todoId} — update or delete a TODO
  • PUT /tasks/{id}/todos/reorder — reorder TODOs
  • GET | POST /tasks/{id}/dependencies — list or add dependencies
  • DELETE /tasks/{id}/dependencies/{dependencyId} — remove a dependency
  • GET /tasks/{id}/dependents — list dependent tasks
  • GET | POST /tasks/{id}/clarifications — list or request clarifications
  • WebSocket /tasks-api/api/v1/ws/tasks — receive live task updates

Payload example

Create and complete a task

Create request

POST /tasks-api/api/v1/tasks

{
  "name": "Review Q3 supplier contract",
  "description": "Check renewal terms and summarize commercial risks.",
  "priority": "high",
  "assignedTo": {
    "type": "agent",
    "id": "agent_legal_01",
    "name": "Legal Analyst"
  },
  "dueDateTime": "2026-08-15T16:00:00Z",
  "context": { "supplierId": "sup_204" },
  "todos": [
    { "description": "Review renewal and termination clauses", "order": 1 },
    { "description": "Prepare a risk summary", "order": 2 }
  ]
}

Create response

{
  "id": "67a30f1c41b6d2a71f003e99",
  "uri": "unago://tasks/67a30f1c41b6d2a71f003e99",
  "name": "Review Q3 supplier contract",
  "status": "pending",
  "priority": "high",
  "isBlocked": false,
  "createdAt": "2026-08-11T10:00:00Z"
}

Status update

PUT /tasks-api/api/v1/tasks/67a30f1c41b6d2a71f003e99/status

{
  "status": "completed",
  "result": "Review complete. Two renewal risks require approval."
}

Tasks API

Personal automations

Base path: /tasks-api/api/v1/automations

Personal automations are user-owned task recipes with one-time or recurring schedules. Ownership is derived from the authenticated identity.

  • GET /automations — list owned automations with limit, offset, and optional agentId
  • POST /automations — create an automation
  • PATCH /automations/{automationId} — update its schedule or task settings
  • POST /automations/{automationId}/run — trigger an immediate run

Payload example

Create and trigger a personal automation

Create request

POST /tasks-api/api/v1/automations

{
  "name": "Weekday pipeline summary",
  "taskDescription": "Summarize pipeline movement and highlight blocked deals.",
  "todos": [
    "Read the latest CRM changes",
    "Group material movement by owner",
    "Write an executive summary"
  ],
  "agent": {
    "type": "agent",
    "id": "agent_sales_01",
    "name": "Sales Analyst"
  },
  "schedule": {
    "type": "recurring",
    "cronPattern": "0 9 * * 1-5",
    "timezone": "Europe/London",
    "enabled": true
  },
  "reuseConversation": true
}

Create response

{
  "id": "67a3152d41b6d2a71f004010",
  "name": "Weekday pipeline summary",
  "status": "active",
  "todos": [
    "Read the latest CRM changes",
    "Group material movement by owner",
    "Write an executive summary"
  ],
  "reuseConversation": true,
  "runAsUser": false
}

Immediate run request

POST /tasks-api/api/v1/automations/67a3152d41b6d2a71f004010/run

{ "confirmed": true }

Storage API

Files, directories, search, and sharing

Preferred base path: /storage-api/api/v2/storage

Use /user-data for private files and /company-data for company-shared files. Uploads use multipart/form-data; JSON operations use camelCase fields.

  • GET /files?path={path}&limit={limit}&offset={offset} — list a directory
  • POST /files/upload — upload a file
  • GET | HEAD /files/download?path={path} — download or probe by path
  • GET /files/search — search files
  • POST /files/copy | /move — copy or move by path
  • DELETE /files?path={path} — delete by path
  • GET /files/{fileId}/metadata — retrieve file metadata
  • GET | PUT /files/{fileId}/content — read or replace text content
  • GET /files/{fileId}/download — download by file ID
  • POST /files/{fileId}/copy | /move — copy or move by file ID
  • DELETE /files/{fileId} — delete by file ID
  • POST | DELETE /directories — create or delete a directory
  • DELETE /batch — delete multiple files and folders
  • GET /bindings — list connected folder bindings
  • POST /files/share | /files/{fileId}/share — create a public share
  • POST /files/public-link — generate a public link

Payload example

Upload and move a file

Multipart upload

The file part must be sent last so the service can stream it directly to storage.

curl -X POST "$BASE_URL/storage-api/api/v2/storage/files/upload" \
  -H "Authorization: Bearer $TOKEN" \
  -F "path=/user-data/reports/q3-review.pdf" \
  -F "overwrite=true" \
  -F "file=@q3-review.pdf;type=application/pdf"

Upload response

{
  "success": true,
  "fileId": "fil_85e03",
  "path": "/user-data/reports/q3-review.pdf",
  "hyperionURI": "unago://files/user-data/reports/q3-review.pdf",
  "outputUri": "unago://files/user-data/reports/q3-review.pdf",
  "size": 248193,
  "checksum": "sha256:7e2d...",
  "uploadedAt": "2026-08-11T10:15:00Z",
  "scope": "user"
}

Move request

POST /storage-api/api/v2/storage/files/move

{
  "source": "/user-data/reports/q3-review.pdf",
  "destination": "/company-data/contracts/q3-review.pdf"
}

API conventions

Headers, pagination, IDs, and timestamps

Use HTTPS for every request. JSON fields and URL parameters use camelCase. Resource IDs are opaque strings and should never be parsed for business meaning.

  • Authorization: Bearer <JWT> — required on protected endpoints
  • Content-Type: application/json — required for JSON request bodies
  • Content-Type: multipart/form-data — required for file uploads
  • limit and offset — standard list pagination inputs
  • total and hasMore — standard list pagination metadata where supported
  • ISO 8601 UTC — timestamp format, for example 2026-08-11T10:15:00Z
  • unago://files/... — canonical file URI returned by Storage API
  • 2xx — success; 4xx — request or authorization error; 5xx — service failure

Error handling

Treat every non-2xx response as a failure

Preserve the status code and safe error details in integration logs. Never log tokens, passwords, uploaded file contents, or private record values.

Validation error

{
  "error": "Invalid request body",
  "details": {
    "field": "status",
    "message": "status is required"
  }
}

Recommended client handling

const response = await fetch(url, options);
const payload = await response.json();

if (!response.ok) {
  throw new Error(payload.error || `HTTP ${response.status}`);
}

return payload;

FAQ

Integration FAQ

Common implementation questions for external platform teams.

Which base URL should my integration use?

Use the HTTPS origin assigned to your environment. Keep it configurable so development, staging, and production can use separate values without code changes.

How should tokens be stored?

Keep tokens in a secure server-side secret store or protected runtime memory. Do not place them in URLs, source code, analytics events, or application logs.

How should list pagination be implemented?

Send limit and offset, retain the returned total where available, and continue only while hasMore is true. Apply a deterministic sort when stable ordering matters.

Which file URI should integrations persist?

Persist the canonical unago://files/... value returned by Storage API. Use the corresponding download or metadata endpoint when the file is needed later.

Build with UnaGo

Plan your integration with the platform team

Share your target workflow, expected request volume, and security requirements so the integration can be reviewed before launch.