Skip to content

Welcome to Aiwyn API

The Aiwyn API provides programmatic access to our comprehensive suite of financial automation tools. Build powerful integrations and automate your accounting workflows with our RESTful APIs.

Key Features

  • 🔐 Secure Authentication - Industry-standard OAuth 2.0 and API key authentication
  • 📊 Real-time Data - Access up-to-date financial information
  • 🚀 High Performance - Low latency, high throughput API infrastructure
  • 📚 Comprehensive Coverage - Full access to clients, engagements, expenses, and more
  • 🛠️ Developer-Friendly - Extensive documentation, SDKs, and code examples

API Versioning

We use URL versioning for our APIs. The current version is v1. All endpoints are prefixed with the version number.

Testing Enviornments

  • Sandbox runs the latest development branch.
  • Staging mirrors production behavior and stability.
Download OpenAPI description
Overview
Languages
Servers
Mock server
https://api.doc.aiwyn.ai/_mock/bundle
Sandbox
https://demo.api.aiwyn.ai
Staging
https://staging.api.aiwyn.app

🔐 Authentication

Authentication endpoints for obtaining access tokens and managing API keys.

Operations

👤 Client

Manage client records, profiles, and related operations.

Operations

📇 Contact

Manage contact information and relationships for clients.

Operations

🧩 Client Business Entity

Manage client business entities used for client categorization and structure.

Operations

🔗 Contact Client

Manage contact ↔ client relationship records.

Operations

🪪 Contact Info

Manage contact information records (address, email, phone, etc.).

Operations

🏢 Department

Manage departments and organizational units.

Operations

🏭 Industry

Manage industry classifications.

Operations
Operations

🧩 Job Template

Manage job templates.

Operations

🏬 Office

Manage office locations.

Operations
Operations

🧷 Service Line

Manage service line classifications.

Operations

🧑‍💼 Staff

Manage staff accounts, roles, and permissions.

Operations

💳 Payments

Handle incoming and outgoing payments.

Operations

🧾 Billing

Manage billing cycles, statements, and billing configurations.

Operations

📄 Invoices

Create, send, and manage invoices.

Operations

📋 Projects

Handle engagements, projects, and workflow tracking.

Operations

⏱ Time

Track and manage billable and non-billable time entries.

Operations

✉️ Engagement

Create, send, and track engagement.

Operations

🛤 Last Mile

Handle the final delivery stage and client closing processes.

🗃️ Records

Create, update, and manage entity records across standard and custom record types.

The Records API provides:

  • Record Operations - Create, update, and delete records for any entity type
  • Schema Discovery - Query available entity types and their field definitions
  • Custom Record Types - Define and manage custom record type schemas
Operations

🔔 Event Subscriptions

Create and manage webhook subscriptions for entity events.

The Event Subscriptions API provides:

  • Webhook Management - Create, update, and deactivate webhook subscriptions
  • Event Filtering - Subscribe to specific entity types and operations (CREATE, UPDATE, DELETE)
  • Security - Retrieve webhook signing secrets for payload verification
Operations

Request

Get catalog of available event types

Returns all entity/operation combinations that can be subscribed to. Use the 'enabled' query parameter to filter by enabled status.

Business Applications:

  • Discover available events
  • Integration planning
Security
BearerAuth
curl -i -X GET \
  https://api.doc.aiwyn.ai/_mock/bundle/api/v1/event-subscriptions/catalog \
  -H 'Authorization: Bearer <YOUR_JWT_HERE>'

Responses

Event Subscriptions updated successfully

Bodyapplication/json
object
Response
application/json
{}

Request

Create a webhook subscription for entity events

Subscribe to receive webhook notifications when entities are created, updated, or deleted. The webhook URL must use HTTPS and will receive POST requests with event data.

Business Applications:

  • Real-time integrations
  • Event-driven workflows
  • System synchronization

Real Example:

curl --location 'https://{{host}}/api/v1/event-subscriptions' \
--header 'Authorization: bearer {{token}}' \
--header 'Content-Type: application/json' \
--data '{
  "entityType": example value,
  "operation": example value,
  "deliveryUrl": "example value"
}'
Security
BearerAuth
Bodyapplication/jsonrequired
entityTypeobjectrequired

Entitytype

operationobjectrequired

Operation

deliveryUrlstringrequired

Deliveryurl

filterExpressionstring or null

Filterexpression

descriptionstring or null

Description

curl -i -X POST \
  https://api.doc.aiwyn.ai/_mock/bundle/api/v1/event-subscriptions \
  -H 'Authorization: Bearer <YOUR_JWT_HERE>' \
  -H 'Content-Type: application/json' \
  -d '{
    "entityType": {},
    "operation": {},
    "deliveryUrl": "string",
    "filterExpression": "string",
    "description": "string"
  }'

Responses

Event Subscriptions created successfully

Bodyapplication/json
dataobject
errorobject or null
metaobject
Response
application/json
{ "data": { "subscription": {}, "webhookSecret": "string", "webhookSecretInstructions": "string" }, "error": {}, "meta": { "success": true, "message": "string", "timestamp": "2019-08-24T14:15:22Z", "version": "string" } }

Request

Update an existing webhook subscription

Modify subscription properties such as delivery URL, filter expression, or description. Only provided fields will be updated.

Business Applications:

  • Update webhook URLs
  • Modify event filters
Security
BearerAuth
Bodyapplication/jsonrequired
entityTypeobject or null

Entitytype

operationobject or null

Operation

deliveryUrlstring or null

Deliveryurl

filterExpressionstring or null

Filterexpression

descriptionstring or null

Description

activeboolean or null

Active

curl -i -X PATCH \
  'https://api.doc.aiwyn.ai/_mock/bundle/api/v1/event-subscriptions/{id}' \
  -H 'Authorization: Bearer <YOUR_JWT_HERE>' \
  -H 'Content-Type: application/json' \
  -d '{
    "entityType": {},
    "operation": {},
    "deliveryUrl": "string",
    "filterExpression": "string",
    "description": "string",
    "active": true
  }'

Responses

Event Subscriptions updated successfully

Bodyapplication/json
dataobject
errorobject or null
metaobject
Response
application/json
{ "data": { "id": 0, "staffId": 0, "entityType": {}, "operation": {}, "deliveryUrl": "string", "description": "string", "filterExpression": "string", "active": true, "status": "string", "createdAt": "2019-08-24T14:15:22Z", "updatedAt": "2019-08-24T14:15:22Z", "isInternal": true }, "error": {}, "meta": { "success": true, "message": "string", "timestamp": "2019-08-24T14:15:22Z", "version": "string" } }

Request

Deactivate a webhook subscription

Soft-deletes a subscription by marking it as inactive. The subscription can be reactivated later if needed.

Business Applications:

  • Stop receiving webhooks
  • Cleanup unused subscriptions
Security
BearerAuth
curl -i -X DELETE \
  'https://api.doc.aiwyn.ai/_mock/bundle/api/v1/event-subscriptions/{id}' \
  -H 'Authorization: Bearer <YOUR_JWT_HERE>'

Responses

Event Subscriptions deleted successfully - No content returned

Request

Reactivate a webhook subscription

Reactivates a previously deactivated subscription.

Business Applications:

  • Restore webhook integrations
  • Resume event notifications

Real Example:

curl --location 'https://{{host}}/api/v1/event-subscriptions/{id}/reactivate' \
--header 'Authorization: bearer {{token}}' \
--header 'Content-Type: application/json' \
Security
BearerAuth
curl -i -X POST \
  'https://api.doc.aiwyn.ai/_mock/bundle/api/v1/event-subscriptions/{id}/reactivate' \
  -H 'Authorization: Bearer <YOUR_JWT_HERE>'

Responses

Event Subscriptions created successfully

Bodyapplication/json
dataobject
errorobject or null
metaobject
Response
application/json
{ "data": { "id": 0, "staffId": 0, "entityType": {}, "operation": {}, "deliveryUrl": "string", "description": "string", "filterExpression": "string", "active": true, "status": "string", "createdAt": "2019-08-24T14:15:22Z", "updatedAt": "2019-08-24T14:15:22Z", "isInternal": true }, "error": {}, "meta": { "success": true, "message": "string", "timestamp": "2019-08-24T14:15:22Z", "version": "string" } }

Retrieve webhook delivery attempts for a subscription

Request

Retrieve webhook delivery attempts for a subscription

Returns a paginated list of delivery attempts for webhook events for the given subscription. Supports filtering by HTTP status code and time range.

Business Applications:

  • Webhook troubleshooting
  • Delivery monitoring
  • Operational auditing
Security
BearerAuth
curl -i -X GET \
  'https://api.doc.aiwyn.ai/_mock/bundle/api/v1/event-subscriptions/{id}/deliveries' \
  -H 'Authorization: Bearer <YOUR_JWT_HERE>'

Responses

Event Subscriptions updated successfully

Bodyapplication/json
object
Response
application/json
{}

Request

Get the webhook signing secret

Retrieves the secret used to sign webhook payloads. Use this secret to verify webhook authenticity on your server.

Business Applications:

  • Webhook signature verification
  • Security setup
Security
BearerAuth
curl -i -X GET \
  https://api.doc.aiwyn.ai/_mock/bundle/api/v1/event-subscriptions/webhook/secret \
  -H 'Authorization: Bearer <YOUR_JWT_HERE>'

Responses

Event Subscriptions updated successfully

Bodyapplication/json
object
Response
application/json
{}

Generate a test webhook payload and signature

Request

Generate a signed test webhook payload

Generates a signature for an arbitrary JSON payload using the provided secret. This is intended for debugging webhook integrations.

Business Applications:

  • Webhook troubleshooting
  • Signature validation testing

Real Example:

curl --location 'https://{{host}}/api/v1/webhook/test/generate' \
--header 'Authorization: bearer {{token}}' \
--header 'Content-Type: application/json' \
Security
BearerAuth
curl -i -X POST \
  https://api.doc.aiwyn.ai/_mock/bundle/api/v1/webhook/test/generate \
  -H 'Authorization: Bearer <YOUR_JWT_HERE>'

Responses

Event Subscriptions created successfully

Bodyapplication/json
dataobject
errorobject or null
metaobject
Response
application/json
{ "data": { "isValid": true, "payload": {}, "signature": "string", "secret": "string" }, "error": {}, "meta": { "success": true, "message": "string", "timestamp": "2019-08-24T14:15:22Z", "version": "string" } }

Request

Validate a webhook signature

Verifies that the provided signature matches the payload and secret. This is intended for debugging webhook integrations.

Business Applications:

  • Webhook troubleshooting
  • Signature validation testing

Real Example:

curl --location 'https://{{host}}/api/v1/webhook/test/validate' \
--header 'Authorization: bearer {{token}}' \
--header 'Content-Type: application/json' \
Security
BearerAuth
curl -i -X POST \
  https://api.doc.aiwyn.ai/_mock/bundle/api/v1/webhook/test/validate \
  -H 'Authorization: Bearer <YOUR_JWT_HERE>'

Responses

Event Subscriptions created successfully

Bodyapplication/json
object
Response
application/json
{}

📁 File

Download and access files associated with records and documents.

Operations