Operations
Get an asynchronous operation
Returns one asynchronous operation from the active organization. Use this endpoint to get an asynchronous operation through the Samva email API.
GET
Returns one asynchronous operation from the active organization.
apiKeyheader
x-api-key<token>id*stringMatch
^op_[0-9a-hjkmnp-tv-z]{16,24}$Operation
application/json- response
id*OperationIdMatch
^op_[0-9a-hjkmnp-tv-z]{16,24}$organizationId*stringkind*stringValue in
"email-domain-provisioning""organization-deletion"subject*actor*status*stringValue in
"pending""running""succeeded""failed"phase*stringValue in
"accepted""dispatching""provisioning""deleting""finalizing""completed"error*|nullcreatedAt*stringupdatedAt*stringstartedAt*string|nullcompletedAt*string|nullimport { createClient } from "samva";const samva = createClient({ apiKey: process.env.SAMVA_API_KEY! });const result = await samva.operations.get({ "id": "example"});Example Response
{ "id": "string", "organizationId": "string", "kind": "email-domain-provisioning", "subject": { "type": "string", "id": "string" }, "actor": { "type": "user", "id": "string" }, "status": "pending", "phase": "accepted", "error": { "code": "validation-failed", "message": "string" }, "createdAt": "string", "updatedAt": "string", "startedAt": "string", "completedAt": "string"}Related documentation
Update the current organization
Updates the current organization's profile, avatar, regional defaults, and reply-to default and returns the saved organization.
List asynchronous operations
Lists asynchronous operations for the active organization, newest first. Pass `nextCursor` back as `cursor` for the next page; it is null on the last page.