Agende sua consultoria gratuita

API Guide

Perfex REST API

by Tecno Center

👋 Introduction

Perfex API operates over HTTP/HTTPS and uses JSON as its data format. It is a RESTful API and utilizes HTTP methods and HTTP status codes to specify requests and responses.
To get started using the API you first need an API token, after activating our module, through your API Management section (Perfex CRM’s admin dashboard) and assign the respective permissions to it.


👨‍💻 Installation

→ Download our API module from CodeCanyon and upload it in the Modules section of your Perfex CRM installation.
→ Press Activate and enter your license key.


✏️ Create an API token

→ Sign in into Perfex’s CRM backend as an admin, go to API → API Management, and create a new token.
→ Make sure to copy the token and that you fill all necessary information (permissions etc).


⛓️ Usage of the API

Available commands of the API are described below, along with their request-response examples for every endpoint.
We are using authtoken header value for authentication and multipart-form type for data operations (POST/PUT).

If you are not familiar with REST APIs, we strongly suggest that you hire a professional, in order to have your third party connections done.
Familiarization with REST APIs is a prerequisite for this item and getting you into its learning falls outside the scope of the support of this item.


📇 Sample usage (example command)

Scenario: Your token is jEheVytlAoFl7F8MqUQ7jAo2hOXAS and that you need to list all available customers of your Perfex’s installation, through a cURL request.

Use Case: You will need to execute the following terminal command:

curl -H "authtoken: jEheVytlAoFl7F8MqUQ7jAo2hOXAS" https://mysite.com/api/customers

The response that you are supposed to receive, under a 200 OK status code, will be similar to the following:

[
   {
      "stripe_id" : null,
      "active" : "1",
      "vat" : "1234567890",
      "address" : "Test Address",
      "billing_country" : "0",
      "phonenumber" : "1234567890",
      "registration_confirmed" : "1",
      "longitude" : null,
      "billing_city" : "",
      "state" : "Test State",
      "shipping_zip" : "",
      "billing_zip" : "",
      "city" : "Test City",
      "shipping_country" : "0",
      "billing_street" : "",
      "datecreated" : "2019-11-29 12:34:56",
      "company" : "Jk Technologies",
      "shipping_street" : "",
      "zip" : "123456",
      "billing_state" : "",
      "leadid" : null,
      "addedfrom" : "8",
      "userid" : "3",
      "default_language" : "english",
      "shipping_state" : "",
      "show_primary_contact" : "0",
      "country" : "102",
      "default_currency" : "3",
      "shipping_city" : "",
      "latitude" : null,
      "website" : "https://example.com"
   },
   {
      "website" : "https://example2.com",
      "latitude" : null,
      "default_currency" : "0",
      "shipping_city" : "London",
      "country" : "235",
      "show_primary_contact" : "0",
      "shipping_state" : "Greater London",
      "default_language" : "",
      "addedfrom" : "1",
      "userid" : "1",
      "leadid" : null,
      "billing_state" : "Greater London",
      "zip" : "WC1 ASW",
      "shipping_street" : "123 Road Street",
      "company" : "Sample Company LTD",
      "datecreated" : "2019-04-02 13:38:28",
      "billing_street" : "123 Road Street",
      "shipping_country" : "235",
      "city" : "London",
      "billing_zip" : "WC1 ASW",
      "shipping_zip" : "WC1 ASW",
      "longitude" : null,
      "registration_confirmed" : "1",
      "billing_city" : "London",
      "state" : "Greater London",
      "phonenumber" : "+44 210 7298299",
      "billing_country" : "235",
      "address" : "123 Road Street",
      "vat" : "123456789",
      "active" : "1",
      "stripe_id" : null
   }
]

⚛ Custom fields

All commands do support custom fields (starting from version 1.0.2).

Please take a look at the Custom Fields section in order to ensure the correct implementation of each request that includes Custom Fields.

Zapier

Zapier – List Available Resources

Returns a list of all available resources that can be used for polling and testing. This endpoint is used by automation platforms to discover available triggers.

GETyourdomain.com/api/zapier/resources

Header

FieldTypeDescription
authtokenStringAuthentication token, generated from admin area
Authorization (optional)StringBearer token (alternative to authtoken header)

Success 200

FieldTypeDescription
statusBooleanRequest status
dataArrayArray of available resources
data[]String.key Resource key identifier
HTTP/1.1 200 OK
{
  "status": true,
  "data": [
    {
      "key": "customers",
      "label": "Customers",
      "description": "New or updated customers"
    },
    {
      "key": "invoices",
      "label": "Invoices",
      "description": "New or updated invoices"
    },
    {
      "key": "leads",
      "label": "Leads",
      "description": "New or updated leads"
    },
    {
      "key": "tasks",
      "label": "Tasks",
      "description": "New or updated tasks"
    },
    {
      "key": "tickets",
      "label": "Tickets",
      "description": "New or updated support tickets"
    }
  ]
}

Zapier – Poll for New Data

Polling endpoint used by automation platforms (Zapier, Make.com, n8n) to retrieve new or updated records. Returns records that were created or modified after the specified timestamp.

GETyourdomain.com/api/zapier/poll/{resource}

Header

FieldTypeDescription
authtokenStringAuthentication token, generated from admin area
Authorization (optional)StringBearer token (alternative to authtoken header)

Parameter

FieldTypeDescription
resourceStringResource name. Must be one of: customers, invoices, leads, tasks, tickets
since (optional)NumberUnix timestamp to filter records created/updated after this time. Default: last 24 hours
limit (optional)NumberMaximum number of records to return. Default: 50

Success 200

FieldTypeDescription
statusBooleanRequest status
dataArrayArray of resource records
metaObjectMetadata object
  sinceNumberTimestamp used for filtering
  countNumberNumber of records returned
  next_pollNumberRecommended timestamp for next poll

Error 4xx

NameTypeDescription
statusBooleanRequest status
messageStringError message
HTTP/1.1 200 OK
{
  "status": true,
  "data": [
    {
      "id": "1",
      "company": "Example Company",
      "datecreated": "2024-01-15 10:30:00"
    }
  ],
  "meta": {
    "since": 1705312200,
    "count": 1,
    "next_poll": 1705315800
  }
}
HTTP/1.1 400 Bad Request
{
  "status": false,
  "message": "Resource parameter required"
}

Zapier – Test Trigger

Returns sample data for testing automation triggers. Used by automation platforms to validate trigger configuration and show sample data structure to users.

GETyourdomain.com/api/zapier/test/{resource}

Header

FieldTypeDescription
authtokenStringAuthentication token, generated from admin area
Authorization (optional)StringBearer token (alternative to authtoken header)

Parameter

FieldTypeDescription
resourceStringResource name. Must be one of: customers, invoices, leads, tasks, tickets

Success 200

FieldTypeDescription
statusBooleanRequest status
dataObjectSample data record for the specified resource

Error 4xx

NameTypeDescription
statusBooleanRequest status
messageStringError message
HTTP/1.1 200 OK
{
  "status": true,
  "data": {
    "id": 1,
    "company": "Sample Company",
    "email": "sample@example.com",
    "phone": "+1234567890"
  }
}
HTTP/1.1 400 Bad Request
{
  "status": false,
  "message": "Resource parameter required"
}

Zapier – Zapier Route Handler

This is a routing method that maps to specific Zapier endpoints. Use the direct endpoints (poll_get, test_get, resources_get) instead.

GETyourdomain.com/api/zapier/{method}/{resource}

Header

FieldTypeDescription
authtokenStringAuthentication token, generated from admin area
Authorization (optional)StringBearer token (alternative to authtoken header)

Parameter

FieldTypeDescription
methodStringMethod name (poll, test, resources)
resource (optional)StringResource name (customers, invoices, leads, tasks, tickets) – required for poll and test methods

Success 200

FieldTypeDescription
statusBooleanRequest status
dataMixedResponse data

Error 4xx

NameTypeDescription
statusBooleanRequest status
errorStringError message
HTTP/1.1 404 Not Found
{
  "error": "Method not found: invalid_get"
}

Calendar Events

Calendar_Events – Create a new Calendar Event

POSTyourdomain.com/api/calendar/

Header

FieldTypeDescription
authtokenStringAuthentication token, generated from admin area

Parameter

FieldTypeDescription
titleStringRequired event title.
descriptionStringOptional event description.
startDateRequired event start date.
reminder_before_typeStringRequired value of reminder before type.
reminder_beforeNumberRequired value of reminder before.
colorStringOptional event color.
useridNumberRequired user id.
isstartnotifiedNumberRequired isstartnotified status.
publicNumberRequired public status.
HTTP/1.1 200 OK
 {
     "status": true,
     "message": "Data Added Successfully"
 }
   HTTP/1.1 404 Not Found
{
    "status": false,
    "message": "Data Creation Failed"
}

Calendar_Events – Delete a Calendar Event

DELETEyourdomain.com/api/calendar/:id

Header

FieldTypeDescription
authtokenStringAuthentication token, generated from admin area

Parameter

FieldTypeDescription
IDNumberID for data deletion.
HTTP/1.1 200 OK
{
  "status": true,
  "message": "Data Deleted Successfully"
}
HTTP/1.1 404 Not Found
{
  "status": false,
  "message": "Data Delete Fail"
}

Calendar_Events – Get All Calendar Events

GETyourdomain.com/api/calendar/

Header

FieldTypeDescription
authtokenStringAuthentication token, generated from admin area
HTTP/1.1 200 OK
[
    {
        "eventid": "1",
        "title": "Hello",
        "description": "test",
        "userid": "1",
        "start": "2023-12-12 07:00:00",
        "end": 2023-12-12 07:00:00,
        "public": "1",
        "color": "#03a9f4",
        "isstartnotified": "0",
        "reminder_before": "30",
        "reminder_before_type": "minutes"
    },
    {
        "eventid": "2",
        "title": "Hello2",
        "description": "test2",
        "userid": "2",
        "start": "2022-12-12 07:00:00",
        "end": 2022-12-12 07:00:00,
        "public": "0",
        "color": "#03a9f4",
        "isstartnotified": "0",
        "reminder_before": "3",
        "reminder_before_type": "hours"
    }
]
HTTP/1.1 404 Not Found
{
    "status": false,
    "message": "No data were found"
}

Calendar_Events – Request Specific Event Information

GETyourdomain.com/api/calendar/:id

Header

FieldTypeDescription
authtokenStringAuthentication token, generated from admin area

Parameter

FieldTypeDescription
ididEvent data by id.
HTTP/1.1 200 OK
[
    {
        "eventid": "1",
        "title": "Hello",
        "description": "test",
        "userid": "1",
        "start": "2023-12-12 07:00:00",
        "end": 2023-12-12 07:00:00,
        "public": "1",
        "color": "#03a9f4",
        "isstartnotified": "0",
        "reminder_before": "30",
        "reminder_before_type": "minutes"
    }
]
HTTP/1.1 404 Not Found
{
    "status": false,
    "message": "No data were found"
}

Calendar_Events – Update a Calendar Event

PUTyourdomain.com/api/calendar/:id

Header

FieldTypeDescription
authtokenStringAuthentication token, generated from admin area

Parameter

FieldTypeDescription
uniqueidID for update data.
HTTP/1.1 200 OK
{
  "status": true,
  "message": "Data Update Successful."
}
   HTTP/1.1 404 Not Found
{
     "status": false,
     "message": "Data Update Fail"
}

Common

Common – Get Common Data

Retrieves common system data based on the specified type. This endpoint is an alias for the Common controller’s data_get method.

GETyourdomain.com/api/common/{type}

Header

FieldTypeDescription
authtokenStringAuthentication token, generated from admin area

Parameter

FieldTypeDescription
typeStringData type. Must be one of: expense_category, payment_mode, tax_data

Success 200

FieldTypeDescription
ArrayArrayof common data records (format depends on type)

Error 4xx

NameTypeDescription
statusBooleanRequest status
messageStringError message
HTTP/1.1 200 OK
[
  {
    "id": "1",
    "name": "expense category name",
    "description": "description"
  }
]
HTTP/1.1 404 Not Found
{
  "status": false,
  "message": "Not valid data"
}
HTTP/1.1 200 OK
[
  {
    "id": "1",
    "name": "cloud server",
    "description": "AWS server"
  }
]
HTTP/1.1 404 Not Found
{
  "status": false,
  "message": "Not valid data"
}

Contacts

Contacts – Add New Contact

POSTyourdomain.com/api/contacts/

Header

FieldTypeDescription
authtokenStringAuthentication token, generated from admin area

Parameter

FieldTypeDescription
customer_idNumberMandatory Customer id.
firstnameStringMandatory First Name
lastnameStringMandatory Last Name
emailStringMandatory E-mail
title (optional)StringOptional Position
phonenumber (optional)StringOptional Phone Number
direction (optional)StringOptional Direction (rtl or ltr)Default value: rtl
password (optional)StringOptional password (only required if you pass send_set_password_email parameter)
is_primary (optional)StringOptional Primary Contact (set on or don’t pass it)Default value: on
donotsendwelcomeemail (optional)StringOptional Do Not Send Welcome Email (set on or don’t pass it)
send_set_password_email (optional)StringOptional Send Set Password Email (set on or don’t pass it)
permissions (optional)ArrayOptional Permissions for this contact([“1”, “2”, “3”, “4”, “5”, “6” ])
[
“1”, // Invoices permission
“2”, // Estimates permission
“3”, // Contracts permission
“4”, // Proposals permission
“5”, // Support permission
“6” // Projects permission
]
invoice_emails (optional)StringOptional E-Mail Notification for Invoices (set value same as name or don’t pass it)Default value: invoice_emails
estimate_emails (optional)StringOptional E-Mail Notification for Estimate (set value same as name or don’t pass it)Default value: estimate_emails
credit_note_emails (optional)StringOptional E-Mail Notification for Credit Note (set value same as name or don’t pass it)Default value: credit_note_emails
project_emails (optional)StringOptional E-Mail Notification for Project (set value same as name or don’t pass it)Default value: project_emails
ticket_emails (optional)StringOptional E-Mail Notification for Tickets (set value same as name or don’t pass it)Default value: ticket_emails
task_emails (optional)StringOptional E-Mail Notification for Task (set value same as name or don’t pass it)Default value: task_emails
contract_emails (optional)StringOptional E-Mail Notification for Contract (set value same as name or don’t pass it)Default value: contract_emails

Success 200

FieldTypeDescription
statusBooleanRequest status.
messageStringContact added successfully.

Error 4xx

NameTypeDescription
statusBooleanRequest status
messageStringContact add fail
emailStringThis Email is already exists
HTTP/1.1 200 OK
{
  "status": true,
  "message": "Contact added successfully"
}
HTTP/1.1 404 Not Found
{
  "status": false,
  "message": "Contact add fail"
}

Contacts – Delete Contact

DELETEyourdomain.com/api/delete/contacts/:id

Header

FieldTypeDescription
authtokenStringAuthentication token, generated from admin area

Parameter

FieldTypeDescription
customer_idNumberunique Customer id

Success 200

FieldTypeDescription
statusStringRequest status.
messageStringContact Deleted Successfully

Error 4xx

NameTypeDescription
statusBooleanRequest status
messageStringContact Delete Fail
HTTP/1.1 200 OK
{
  "status": true,
  "message": "Contact Deleted Successfully"
}
HTTP/1.1 404 Not Found
{
  "status": false,
  "message": "Contact Delete Fail"
}

Contacts – List all Contacts of a Customer

GETyourdomain.com/api/contacts/:customer_id/:contact_id

Header

FieldTypeDescription
authtokenStringAuthentication token, generated from admin area

Parameter

FieldTypeDescription
customer_idNumberMandatory Customer unique ID
contact_idNumberOptional Contact unique ID
Note : if you don’t pass Contact id then it will list all contacts of the customer

Success 200

FieldTypeDescription
ContactObjectContact information

Error 4xx

NameTypeDescription
statusBooleanRequest status
messageStringNo data were found
    HTTP/1.1 200 OK
	{
		"id": "6",
		"userid": "1",
		"company": "xyz",
		"vat": "",
		"phonenumber": "1234567890",
		"country": "0",
		"city": "",
		"zip": "360005",
		"state": "",
		"address": "",
		"website": "",
		"datecreated": "2020-08-19 20:07:49",
		"active": "1",
		"leadid": null,
		"billing_street": "",
		"billing_city": "",
		"billing_state": "",
		"billing_zip": "",
		"billing_country": "0",
		"shipping_street": "",
		"shipping_city": "",
		"shipping_state": "",
		"shipping_zip": "",
		"shipping_country": "0",
		"longitude": null,
		"latitude": null,
		"default_language": "english",
		"default_currency": "0",
		"show_primary_contact": "0",
		"stripe_id": null,
		"registration_confirmed": "1",
		"addedfrom": "1"
	}
HTTP/1.1 404 Not Found
{
  "status": false,
  "message": "No data were found"
}

Contacts – Search Contact Information

GETyourdomain.com/api/contacts/search/:keysearch

Header

FieldTypeDescription
authtokenStringAuthentication token, generated from admin area

Parameter

FieldTypeDescription
keysearchStringSearch Keywords

Success 200

FieldTypeDescription
ContactObjectContact information

Error 4xx

NameTypeDescription
statusBooleanRequest status
messageStringNo data were found
 HTTP/1.1 200 OK
 {
    "id": "8",
    "userid": "1",
    "is_primary": "0",
    "firstname": "chirag",
    "lastname": "jagani",
    "email": "useremail@gmail.com",
    "phonenumber": "",
    "title": null,
    "datecreated": "2020-05-19 20:07:49",
    "password": "$2a$08$6DLJFalqvJGVymCwW2ppNe9HOG5YUP04vzthXZjOFFUQknxfG6QHe",
    "new_pass_key": null,
    "new_pass_key_requested": null,
    "email_verified_at": "2020-08-28 21:36:06",
    "email_verification_key": null,
    "email_verification_sent_at": null,
    "last_ip": null,
    "last_login": null,
    "last_password_change": null,
    "active": "1",
    "profile_image": null,
    "direction": null,
    "invoice_emails": "0",
    "estimate_emails": "0",
    "credit_note_emails": "0",
    "contract_emails": "0",
    "task_emails": "0",
    "project_emails": "0",
    "ticket_emails": "0",
    "company": "trueline",
    "vat": "",
    "country": "0",
    "city": "",
    "zip": "",
    "state": "",
    "address": "",
    "website": "",
    "leadid": null,
    "billing_street": "",
    "billing_city": "",
    "billing_state": "",
    "billing_zip": "",
    "billing_country": "0",
    "shipping_street": "",
    "shipping_city": "",
    "shipping_state": "",
    "shipping_zip": "",
    "shipping_country": "0",
    "longitude": null,
    "latitude": null,
    "default_language": "english",
    "default_currency": "0",
    "show_primary_contact": "0",
    "stripe_id": null,
    "registration_confirmed": "1",
    "addedfrom": "1"
}
HTTP/1.1 404 Not Found
{
  "status": false,
  "message": "No data were found"
}

Contacts – Update Contact Information

PUTyourdomain.com/api/contacts/:id

Header

FieldTypeDescription
authtokenStringAuthentication token, generated from admin area

Parameter

FieldTypeDescription
idNumberMandatory Customer Contact id.
firstnameStringMandatory First Name
lastnameStringMandatory Last Name
emailStringMandatory E-mail
title (optional)StringOptional Position
phonenumber (optional)StringOptional Phone Number
direction (optional)StringOptional Direction (rtl or ltr)Default value: rtl
password (optional)StringOptional password (only required if you pass send_set_password_email parameter)
is_primary (optional)StringOptional Primary Contact (set on or don’t pass it)Default value: on
donotsendwelcomeemail (optional)StringOptional Do Not Send Welcome Email (set on or don’t pass it)
send_set_password_email (optional)StringOptional Send Set Password Email (set on or don’t pass it)
permissions (optional)ArrayOptional Permissions for this contact([“1”, “2”, “3”, “4”, “5”, “6” ])
[
“1”, // Invoices permission
“2”, // Estimates permission
“3”, // Contracts permission
“4”, // Proposals permission
“5”, // Support permission
“6” // Projects permission
]
invoice_emails (optional)StringOptional E-Mail Notification for Invoices (set value same as name or don’t pass it)Default value: invoice_emails
estimate_emails (optional)StringOptional E-Mail Notification for Estimate (set value same as name or don’t pass it)Default value: estimate_emails
credit_note_emails (optional)StringOptional E-Mail Notification for Credit Note (set value same as name or don’t pass it)Default value: credit_note_emails
project_emails (optional)StringOptional E-Mail Notification for Project (set value same as name or don’t pass it)Default value: project_emails
ticket_emails (optional)StringOptional E-Mail Notification for Tickets (set value same as name or don’t pass it)Default value: ticket_emails
task_emails (optional)StringOptional E-Mail Notification for Task (set value same as name or don’t pass it)Default value: task_emails
contract_emails (optional)StringOptional E-Mail Notification for Contract (set value same as name or don’t pass it)Default value: contract_emails

Success 200

FieldTypeDescription
statusBooleanRequest status
messageStringContact updated successful

Error 4xx

NameTypeDescription
emailStringThis Email is already exists
statusBooleanRequest status
messageStringContact add fail
HTTP/1.1 200 OK
{
  "status": true,
  "message": "Contact Updated Successfully"
}
    HTTP/1.1 409 Conflict
    {
      "status": false,
      "error": {
			"email":"This Email is already exists"
		},
		"message": "This Email is already exists"
    }

Contracts

Contracts – Add New Contract

POSTyourdomain.com/api/contracts

Header

FieldTypeDescription
authtokenStringAuthentication token, generated from admin area

Parameter

FieldTypeDescription
subjectStringMandatory. Contract subject
datestartDateMandatory. Contract start date
clientNumberMandatory. Customer ID
dateendDateOptional. Contract end date
contract_typeNumberOptional. Contract type
contract_valueNumberOptional. Contract value
descriptionStringOptional. Contract description
contentStringOptional. Contract content

Success 200

FieldTypeDescription
statusBooleanRequest status.
messageStringContracts Added Successfully

Error 4xx

NameTypeDescription
statusBooleanRequest status.
messageStringContract add fail
HTTP/1.1 200 OK
{
  "status": true,
  "message": "Contract Added Successfully"
}
HTTP/1.1 404 Not Found
{
  "status": false,
  "message": "Contract ID Exists"
}
HTTP/1.1 200 OK
{
  "status": true,
  "message": "Contract Added Successfully"
}
HTTP/1.1 404 Not Found
{
  "status": false,
  "message": "Contract ID Exists"
}

Contracts – Delete Contract

DELETEyourdomain.com/api/contracts/:id

Header

FieldTypeDescription
authtokenStringAuthentication token, generated from admin area

Success 200

FieldTypeDescription
statusBooleanRequest status.
messageStringContract Deleted Successfully

Error 4xx

NameTypeDescription
statusBooleanRequest status.
messageStringContract Delete Fail
HTTP/1.1 200 OK
{
  "status": true,
  "message": "Contract Deleted Successfully"
}
HTTP/1.1 404 Not Found
{
  "status": false,
  "message": "Contract Delete Fail"
}

Contracts – Request Contract information

GETyourdomain.com/api/contracts/:id

Header

FieldTypeDescription
authtokenStringAuthentication token, generated from admin area

Parameter

FieldTypeDescription
idNumberContact unique ID

Success 200

FieldTypeDescription
ContractsObjectinformation.

Error 4xx

NameTypeDescription
statusBooleanRequest status.
messageStringNo data were found.
  HTTP/1.1 200 OK
	    {
	    "id": "1",
	    "content": "",
	    "description": "Lorem Ipsum is simply dummy text of the printing and typesetting industry. Lorem Ipsum has been the industry's standard dummy text ever since the 1500s, when an unknown printer took a galley of type and scrambled it to make a type specimen book. It has survived not only five centuries, but also the leap into electronic typesetting, remaining essentially unchanged. It was popularised in the 1960s with the release of Letraset sheets containing Lorem Ipsum passages, and more recently with desktop publishing software like Aldus PageMaker including versions of Lorem Ipsum.",
	    "subject": "New Contract",
	    "client": "9",
	    "datestart": "2022-11-21",
	    "dateend": "2027-11-21",
	    "contract_type": "1",
	    "project_id": "0",
	    "addedfrom": "1",
	    "dateadded": "2022-11-21 12:45:58",
	    "isexpirynotified": "0",
	    "contract_value": "13456.00",
	    "trash": "0",
	    "not_visible_to_client": "0",
	    "hash": "31caaa36b9ea1f45a688c7e859d3ae70",
	    "signed": "0",
	    "signature": null,
	    "marked_as_signed": "0",
	    "acceptance_firstname": null,
	    "acceptance_lastname": null,
	    "acceptance_email": null,
	    "acceptance_date": null,
	    "acceptance_ip": null,
	    "short_link": null,
	    "name": "Development Contracts",
	    "userid": "9",
	    "company": "8web",
	    "vat": "",
	    "phonenumber": "",
	    "country": "0",
	    "city": "",
	    "zip": "",
	    "state": "",
	    "address": "",
	    "website": "",
	    "datecreated": "2022-08-11 14:07:26",
	    "active": "1",
	    "leadid": null,
	    "billing_street": "",
	    "billing_city": "",
	    "billing_state": "",
	    "billing_zip": "",
	    "billing_country": "0",
	    "shipping_street": "",
	    "shipping_city": "",
	    "shipping_state": "",
	    "shipping_zip": "",
	    "shipping_country": "0",
	    "longitude": null,
	    "latitude": null,
	    "default_language": "",
	    "default_currency": "0",
	    "show_primary_contact": "0",
	    "stripe_id": null,
	    "registration_confirmed": "1",
	    "type_name": "Development Contracts",
	    "attachments": [],
	    "customfields": [],
	    }

Credit Notes

Credit_Notes – Add New Credit Notes

POSTyourdomain.com/api/credit_notes

Header

FieldTypeDescription
authtokenStringAuthentication token, generated from admin area

Parameter

FieldTypeDescription
clientidNumberMandatory. Customer id
dateDateMandatory. Credit Note Date
numberNumberMandatory. Credit Note Number
currencyNumberMandatory. currency field
newitemsArrayMandatory. New Items to be added
billing_streetStringOptional. Street Address
billing_city (optional)StringOptional. City Name for billing
billing_state (optional)StringOptional. Name of state for billing
billing_zip (optional)NumberOptional. Zip code
billing_country (optional)NumberOptional. Country code
shipping_street (optional)StringOptional. Address of shipping
shipping_city (optional)StringOptional. City name for shipping
shipping_state (optional)StringOptional. Name of state for shipping
shipping_zip (optional)NumberOptional. Zip code for shipping
shipping_country (optional)NumberOptional. Country code
discount_type (optional)StringOptional. before_tax / after_tax discount type
Admin (optional)StringNote] Optional. Admin Note
subtotalDecimalMandatory. calculation based on item Qty, Rate and Tax
totalDecimalMandatory. calculation based on subtotal, Discount and
clientnote (optional)StringOptional. client notes
terms (optional)StringOptional. Terms

Success 200

FieldTypeDescription
statusBooleanRequest status.
messageStringCredit Note Added Successfully

Error 4xx

NameTypeDescription
statusBooleanRequest status.
messageStringCredit Note add fail
newitems[]StringThe Items field is required
numberStringThe Credit Note number is already in use
subtotalStringThe Sub Total field is required
totalStringThe Total field is required
HTTP/1.1 200 OK
{
  "status": true,
  "message": "Credit Note Added Successfully"
}
HTTP/1.1 404 Not Found
{
  "status": false,
  "message": "Credit Note Add Fail"
}

Credit_Notes – Delete Credit Note

DELETEyourdomain.com/api/credit_notes/:id

Header

FieldTypeDescription
authtokenStringAuthentication token, generated from admin area

Success 200

FieldTypeDescription
statusBooleanRequest status.
messageStringCredit Note Deleted Successfully

Error 4xx

NameTypeDescription
statusBooleanRequest status.
messageStringCredit Note Delete Fail
HTTP/1.1 200 OK
{
  "status": true,
  "message": "Credit Note Deleted Successfully"
}
HTTP/1.1 404 Not Found
{
  "status": false,
  "message": "Credit Note Delete Fail"
}

Credit_Notes – Request Credit notes information

GETyourdomain.com/api/credit_notes/:id

Header

FieldTypeDescription
authtokenStringAuthentication token, generated from admin area

Success 200

FieldTypeDescription
CreditObjectnotes information.

Error 4xx

NameTypeDescription
statusBooleanRequest status.
messageStringNo data were found.
    HTTP/1.1 200 OK
    {
	        "id": "2",
	        "clientid": "1",
	        "deleted_customer_name": null,
	        "number": "2",
        "prefix": "CN-",
	        "number_format": "1",
	        "datecreated": "2021-07-30 16:29:46",
	        "date": "2021-08-02",
	        "adminnote": "adminnote2",
        "terms": "",
	        "clientnote": "",
	        "currency": "1",
	        "subtotal": "1200.00",
	        "total_tax": "0.00",
	        "total": "1200.00",
	        "adjustment": "0.00",
	        "addedfrom": "1",
	        "status": "1",
	        "project_id": "0",
	        "discount_percent": "0.00",
	        "discount_total": "0.00",
	        "discount_type": "",
	        "billing_street": "Test",
	        "billing_city": "Test",
	        "billing_state": "Test",
	        "billing_zip": "3000",
	        "billing_country": "102",
	        "shipping_street": "Test",
	        "shipping_city": "Test",
	        "shipping_state": "Test",
	        "shipping_zip": "3000",
	        "shipping_country": "102",
	        "include_shipping": "1",
	        "show_shipping_on_credit_note": "1",
	        "show_quantity_as": "1",
	        "reference_no": "",
	        "userid": "1",
	        "company": "Test",
	        "vat": "",
	        "phonenumber": "01324568903",
	        "country": "102",
	        "city": "Test",
	        "zip": "3000",
	        "state": "Test",
	        "address": "Test",
	        "website": "",
	        "active": "1",
	        "leadid": null,
	        "longitude": null,
	        "latitude": null,
	        "default_language": "",
	        "default_currency": "0",
	        "show_primary_contact": "0",
	        "stripe_id": null,
	        "registration_confirmed": "1",
	        "credit_note_id": "2",
	        "customfields": []
	    }
HTTP/1.1 404 Not Found
{
  "status": false,
  "message": "No data were found"
}

Credit_Notes – Search credit notes item information

GETyourdomain.com/api/credit_notes/search/:keysearch

Header

FieldTypeDescription
authtokenStringAuthentication token, generated from admin area

Parameter

FieldTypeDescription
keysearchStringSearch Keywords

Success 200

FieldTypeDescription
creditObjectnotes Information
	HTTP/1.1 200 OK
    {
	        "id": "2",
	        "clientid": "1",
	        "deleted_customer_name": null,
	        "number": "2",
        "prefix": "CN-",
	        "number_format": "1",
	        "datecreated": "2021-07-30 16:29:46",
	        "date": "2021-08-02",
	        "adminnote": "adminnote2",
        "terms": "",
	        "clientnote": "",
	        "currency": "1",
	        "subtotal": "1200.00",
	        "total_tax": "0.00",
	        "total": "1200.00",
	        "adjustment": "0.00",
	        "addedfrom": "1",
	        "status": "1",
	        "project_id": "0",
	        "discount_percent": "0.00",
	        "discount_total": "0.00",
	        "discount_type": "",
	        "billing_street": "Test",
	        "billing_city": "Test",
	        "billing_state": "Test",
	        "billing_zip": "3000",
	        "billing_country": "102",
	        "shipping_street": "Test",
	        "shipping_city": "Test",
	        "shipping_state": "Test",
	        "shipping_zip": "3000",
	        "shipping_country": "102",
	        "include_shipping": "1",
	        "show_shipping_on_credit_note": "1",
	        "show_quantity_as": "1",
	        "reference_no": "",
	        "userid": "1",
	        "company": "test",
	        "vat": "",
	        "phonenumber": "01324568903",
	        "country": "102",
	        "city": "Test",
	        "zip": "3000",
	        "state": "Test",
	        "address": "Test",
	        "website": "",
	        "active": "1",
	        "leadid": null,
	        "longitude": null,
	        "latitude": null,
	        "default_language": "",
	        "default_currency": "0",
	        "show_primary_contact": "0",
	        "stripe_id": null,
	        "registration_confirmed": "1",
	        "credit_note_id": "2",
	        "customfields": []
	    }
HTTP/1.1 404 Not Found
{
  "status": false,
  "message": "No data were found"
}

Credit_Notes – Update a Credit Note

PUTyourdomain.com/api/credit_notes

Header

FieldTypeDescription
authtokenStringAuthentication token, generated from admin area

Parameter

FieldTypeDescription
clientidNumberMandatory. Customer id
dateDateMandatory. Credit Note Date
numberNumberMandatory. Credit Note Number
currencyNumberMandatory. currency field
newitemsArrayMandatory. New Items to be added
itemsArrayMandatory. Existing items with Id
removed_itemsArrayOptional. Items to be removed
billing_streetStringOptional. Street Address
billing_city (optional)StringOptional. City Name for billing
billing_state (optional)StringOptional. Name of state for billing
billing_zip (optional)NumberOptional. Zip code
billing_country (optional)NumberOptional. Country code
shipping_street (optional)StringOptional. Address of shipping
shipping_city (optional)StringOptional. City name for shipping
shipping_state (optional)StringOptional. Name of state for shipping
shipping_zip (optional)NumberOptional. Zip code for shipping
shipping_country (optional)NumberOptional. Country code
discount_type (optional)StringOptional. before_tax / after_tax discount type
Admin (optional)StringNote] Optional. Admin Note
subtotalDecimalMandatory. calculation based on item Qty, Rate and Tax
totalDecimalMandatory. calculation based on subtotal, Discount and
clientnote (optional)StringOptional. client notes
terms (optional)StringOptional. Terms

Success 200

FieldTypeDescription
statusBooleanRequest status.
messageStringCredit Note Updated Successfully

Error 4xx

NameTypeDescription
statusBooleanRequest status.
messageStringCredit Note Update Fail
newitems[]StringThe Items field is required
numberStringThe Credit Note number is already in use
subtotalStringThe Sub Total field is required
totalStringThe Total field is required
HTTP/1.1 200 OK
{
  "status": true,
  "message": "Credit Note Updated Successfully"
}
HTTP/1.1 404 Not Found
{
  "status": false,
  "message": "Credit Note Update Fail"
}

Custom Fields

Custom_Fields – Add Custom Fields

Submit URL for POST request of the custom fields remains the same for each endpoint (ie api/contacts for Contacts endpoint, api/invoices for Invoices endpoint, etc..)

In this example, we will use the following form data which corresponds to the following custom field types:

custom_fields[invoice][1] = Input Type
custom_fields[invoice][2] = Number
custom_fields[invoice][3] = Textarea
custom_fields[invoice][4] = Radio
custom_fields[invoice][5] = Checkbox
custom_fields[invoice][6] = Multiselect
custom_fields[invoice][7] = Date
custom_fields[invoice][8] = Datetime
custom_fields[invoice][9] = Color
custom_fields[invoice][10] = Link

POSTyourdomain.com/N/A

Parameter

FieldTypeDescription
custom_fields[customFieldType]string/arrayCustom Field Key should be same as field_name returned from Search custom field values’ information
HTTP/1.1 200 OK
 Same as Original request
HTTP/1.1 404 Not Found
Same as Original request

Custom_Fields – Delete Custom Fields

To remove particular custom field value you can use Update action and an empty value in the custom field.
Note: When you delete any record the corresponding custom field data will be automatically deleted.

DELETEyourdomain.com/N/A

Custom_Fields – Request Custom Fields

Custom fields’ data will be returned combined with other request’s information during the initial GET request of each available endpoint (Contacts, Invoices etc) with their respective label and value key

GETyourdomain.com/N/A
HTTP/1.1 200 OK
    {
        "id": "1",
        "sent": "0",
        "datesend": null,
        "clientid": "1",
        "deleted_customer_name": null,
        "number": "10",
        "prefix": "INV-",
        "number_format": "1",
        "datecreated": "2021-05-14 00:44:52",
        "date": "2021-08-28",
        "duedate": "2021-09-27",
        "currency": "1",
        "subtotal": "110.00",
        "total_tax": "0.00",
        "total": "110.00",
        "adjustment": "0.00",
        "addedfrom": "0",
        "hash": "4222d2f53404324ea73535d3c0f2c3f0",
        "status": "1",
        "clientnote": "",
        "adminnote": "",
        "last_overdue_reminder": null,
        "cancel_overdue_reminders": "1",
        "allowed_payment_modes": "a:2:{i:0;s:1:\"1\";i:1;s:1:\"2\";}",
        "token": null,
        "discount_percent": "0.00",
        "discount_total": "0.00",
        "discount_type": "",
        "recurring": "0",
        "recurring_type": null,
        "custom_recurring": "0",
        "cycles": "0",
        "total_cycles": "0",
        "is_recurring_from": null,
        "last_recurring_date": null,
        "terms": "",
        "sale_agent": "0",
        "billing_street": "billing address",
        "billing_city": "billing city name",
        "billing_state": "billing state name",
        "billing_zip": "billing zip code",
        "billing_country": "0",
        "shipping_street": "shipping address",
        "shipping_city": "city name",
        "shipping_state": "state name",
        "shipping_zip": "zip code",
        "shipping_country": "0",
        "include_shipping": "1",
        "show_shipping_on_invoice": "1",
        "show_quantity_as": "1",
        "project_id": "0",
        "subscription_id": "0",
        "short_link": null,
        "symbol": "$",
        "name": "USD",
        "decimal_separator": ".",
        "thousand_separator": ",",
        "placement": "before",
        "isdefault": "1",
        "currencyid": "1",
        "currency_name": "USD",
        "total_left_to_pay": "110.00",
        "items": [
            {
                "id": "1",
                "rel_id": "1",
                "rel_type": "invoice",
                "description": "item description",
                "long_description": "item long description",
                "qty": "1.00",
                "rate": "10.00",
                "unit": "1",
                "item_order": "1",
                "customfields": [
                    {
                        "label": "Input 1",
                        "value": "test 12 item 1"
                    },
                    {
                        "label": "Number 1",
                        "value": "10"
                    },
                    {
                        "label": "Textarea 1",
                        "value": "Lorem Ipsum is simply dummy text of the printing and typesetting industry"
                    },
                    {
                        "label": "Select 1",
                        "value": "Option 1"
                    },
                    {
                        "label": "Multiselect 1",
                        "value": "Option 1, Option 2"
                    },
                    {
                        "label": "Checkbox 1",
                        "value": "Option 1, Option 3"
                    },
                    {
                        "label": "Datepicker 1",
                        "value": "2021-05-06"
                    },
                    {
                        "label": "Datetime Picker 1",
                        "value": "2021-05-06 00:23:25"
                    },
                    {
                        "label": "Colorpicker 1",
                        "value": "#ffffff"
                    },
                    {
                        "label": "Hyperlink 1",
                        "value": "<a>Link</a>"
                    }
                ]
            },
            {
                "id": "2",
                "rel_id": "1",
                "rel_type": "invoice",
                "description": "updated item 2 description",
                "long_description": "updated item 2 logn description",
                "qty": "1.00",
                "rate": "100.00",
                "unit": "",
                "item_order": "2",
                "customfields": [
                    {
                        "label": "Input 1",
                        "value": "test 12 item 2"
                    },
                    {
                        "label": "Number 1",
                        "value": "10"
                    },
                    {
                        "label": "Textarea 1",
                        "value": "Lorem Ipsum is simply dummy text of the printing and typesetting industry"
                    },
                    {
                        "label": "Select 1",
                        "value": "Option 1"
                    },
                    {
                        "label": "Multiselect 1",
                        "value": "Option 1, Option 2"
                    },
                    {
                        "label": "Checkbox 1",
                        "value": "Option 1, Option 3"
                    },
                    {
                        "label": "Datepicker 1",
                        "value": "2021-05-06"
                    },
                    {
                        "label": "Datetime Picker 1",
                        "value": "2021-05-06 00:23:25"
                    },
                    {
                        "label": "Colorpicker 1",
                        "value": "#ffffff"
                    },
                    {
                        "label": "Hyperlink 1",
                        "value": "<a>Link</a>"
                    }
                ]
            }
        ],
        "attachments": [],
        "visible_attachments_to_customer_found": false,
        "client": {
            "userid": "1",
            "company": "updated company",
            "vat": "",
            "phonenumber": "",
            "country": "0",
            "city": "",
            "zip": "",
            "state": "",
            "address": "",
            "website": "",
            "datecreated": "2021-05-14 00:15:06",
            "active": "1",
            "leadid": null,
            "billing_street": "",
            "billing_city": "",
            "billing_state": "",
            "billing_zip": "",
            "billing_country": "0",
            "shipping_street": "",
            "shipping_city": "",
            "shipping_state": "",
            "shipping_zip": "",
            "shipping_country": "0",
            "longitude": null,
            "latitude": null,
            "default_language": "",
            "default_currency": "0",
            "show_primary_contact": "0",
            "stripe_id": null,
            "registration_confirmed": "1",
            "addedfrom": "0"
        },
        "payments": [],
        "scheduled_email": null,
        "customfields": [
            {
                "label": "Input 1",
                "value": "test 12"
            },
            {
                "label": "Number 1",
                "value": "10"
            },
            {
                "label": "Textarea 1",
                "value": "Lorem Ipsum is simply dummy text of the printing and typesetting industry"
            },
            {
                "label": "Select 1",
                "value": "Option 1"
            },
            {
                "label": "Multiselect 1",
                "value": "Option 1, Option 2"
            },
            {
                "label": "Checkbox 1",
                "value": "Option 1, Option 3"
            },
            {
                "label": "Datepicker 1",
                "value": "2021-05-06"
            },
            {
                "label": "Datetime Picker 1",
                "value": "2021-05-06 00:23:25"
            },
            {
                "label": "Colorpicker 1",
                "value": "#ffffff"
            },
            {
                "label": "Hyperlink 1",
                "value": "<a>Link</a>"
            }
        ]
    }
HTTP/1.1 404 Not Found
Same as Original request

Custom_Fields – Request Values of Custom Fields

GETyourdomain.com/api/custom_fields/:FieldBelongsto/:id

Header

FieldTypeDescription
authtokenStringAuthentication token, generated from admin area

Parameter

FieldTypeDescription
FieldBelongstostringBelongs to Mandatory Field Belongs to.Allowed values:
"Company"
,
"Leads"
,
"Customers"
,
"Contacts"
,
"Staff"
,
"Contracts"
,
"Tasks"
,
"Expenses"
,
"Invoice"
,
"Items"
,
"Note"
,
"Estimate"
,
"Contract"
,
"Proposal"
,
"Projects"
,
"Tickets"
id (optional)NumberOptional unique ID.

Success 200

FieldTypeDescription
CustomObjectCustom Fields information with values.

Error 4xx

NameTypeDescription
statusBooleanRequest status.
messageStringNo data were found.
  HTTP/1.1 200 OK
[
    {
        "field_name": "custom_fields[invoice][1]",
        "custom_field_id": "1",
        "label": "Input 1",
        "required": "0",
        "type": "input",
        "value": "input1 data"
    },
    {
        "field_name": "custom_fields[invoice][2]",
        "custom_field_id": "2",
        "label": "Number 1",
        "required": "0",
        "type": "number",
        "value": "12"
    },
    {
        "field_name": "custom_fields[invoice][3]",
        "custom_field_id": "3",
        "label": "Textarea 1",
        "required": "0",
        "type": "textarea",
        "value": "textarea content"
    },
    {
        "field_name": "custom_fields[invoice][4]",
        "custom_field_id": "4",
        "label": "Select 1",
        "required": "0",
        "type": "select",
        "value": "[\"Option 1\"]",
        "options": "[\"Option 1\",\"Option 2\",\"Option 3\"]"
    },
    {
        "field_name": "custom_fields[invoice][5]",
        "custom_field_id": "5",
        "label": "Multiselect 1",
        "required": "0",
        "type": "multiselect",
        "value": "[\"Option 1\",\" Option 2\"]",
        "options": "[\"Option 1\",\"Option 2\",\"Option 3\"]"
    },
    {
        "field_name": "custom_fields[invoice][6]",
        "custom_field_id": "6",
        "label": "Checkbox 1",
        "required": "0",
        "type": "checkbox",
        "value": "[\"Option 1\",\" Option 2\"]",
        "options": "[\"Option 1\",\"Option 2\",\"Option 3\"]"
    },
    {
        "field_name": "custom_fields[invoice][7]",
        "custom_field_id": "7",
        "label": "Datepicker 1",
        "required": "0",
        "type": "date_picker",
        "value": "2021-05-16"
    },
    {
        "field_name": "custom_fields[invoice][8]",
        "custom_field_id": "8",
        "label": "Datetime Picker 1",
        "required": "0",
        "type": "date_picker_time",
        "value": "2021-05-25 23:06:00"
    },
    {
        "field_name": "custom_fields[invoice][9]",
        "custom_field_id": "9",
        "label": "Colorpicker 1",
        "required": "0",
        "type": "colorpicker",
        "value": "#8f1b1b"
    },
    {
        "field_name": "custom_fields[invoice][10]",
        "custom_field_id": "10",
        "label": "Hyperlink 1",
        "required": "0",
        "type": "link",
        "value": "<a href=\"https://google.com\" target=\"_blank\">google</a>"
    }
]
HTTP/1.1 404 Not Found
{
  "status": false,
  "message": "No data were found"
}

Custom_Fields – Search custom field values’ information

Custom fields’ data will be returned combined with other request’s information during the initial SEARCH request of each available endpoint (Contacts, Invoices etc) with their respective label and value key

GETyourdomain.com/N/A
HTTP/1.1 200 OK
    [
        {
            "id": "1",
            "sent": "0",
            "datesend": null,
            "clientid": "1",
            "deleted_customer_name": null,
            "number": "10",
            "prefix": "INV-",
            "number_format": "1",
            "datecreated": "2021-05-14 00:15:06",
            "date": "2021-08-28",
            "duedate": "2021-09-27",
            "currency": "1",
            "subtotal": "110.00",
            "total_tax": "0.00",
            "total": "110.00",
            "adjustment": "0.00",
            "addedfrom": "0",
            "hash": "4222d2f53404324ea73535d3c0f2c3f0",
            "status": "1",
            "clientnote": "",
            "adminnote": "",
            "last_overdue_reminder": null,
            "cancel_overdue_reminders": "1",
            "allowed_payment_modes": "a:2:{i:0;s:1:\"1\";i:1;s:1:\"2\";}",
            "token": null,
            "discount_percent": "0.00",
            "discount_total": "0.00",
            "discount_type": "",
            "recurring": "0",
            "recurring_type": null,
            "custom_recurring": "0",
            "cycles": "0",
            "total_cycles": "0",
            "is_recurring_from": null,
            "last_recurring_date": null,
            "terms": "",
            "sale_agent": "0",
            "billing_street": "",
            "billing_city": "",
            "billing_state": "",
            "billing_zip": "",
            "billing_country": "0",
            "shipping_street": "",
            "shipping_city": "",
            "shipping_state": "",
            "shipping_zip": "",
            "shipping_country": "0",
            "include_shipping": "1",
            "show_shipping_on_invoice": "1",
            "show_quantity_as": "1",
            "project_id": "0",
            "subscription_id": "0",
            "short_link": null,
            "userid": "1",
            "company": "updated company",
            "vat": "",
            "phonenumber": "",
            "country": "0",
            "city": "",
            "zip": "",
            "state": "",
            "address": "",
            "website": "",
            "active": "1",
            "leadid": null,
            "longitude": null,
            "latitude": null,
            "default_language": "",
            "default_currency": "0",
            "show_primary_contact": "0",
            "stripe_id": null,
            "registration_confirmed": "1",
            "invoiceid": "1",
            "customfields": [
                {
                    "label": "Input 1",
                    "value": "test 12"
                },
                {
                    "label": "Number 1",
                    "value": "10"
                },
                {
                    "label": "Textarea 1",
                    "value": "Lorem Ipsum is simply dummy text of the printing and typesetting industry"
                },
                {
                    "label": "Select 1",
                    "value": "Option 1"
                },
                {
                    "label": "Multiselect 1",
                    "value": "Option 1, Option 2"
                },
                {
                    "label": "Checkbox 1",
                    "value": "Option 1, Option 3"
                },
                {
                    "label": "Datepicker 1",
                    "value": "2021-05-06"
                },
                {
                    "label": "Datetime Picker 1",
                    "value": "2021-05-06 00:23:25"
                },
                {
                    "label": "Colorpicker 1",
                    "value": "#ffffff"
                },
                {
                    "label": "Hyperlink 1",
                    "value": "<a>Link</a>"
                }
            ]
        },
        {
            "id": "2",
            "sent": "0",
            "datesend": null,
            "clientid": "1",
            "deleted_customer_name": null,
            "number": "4",
            "prefix": "INV-",
            "number_format": "1",
            "datecreated": "2021-05-14 00:15:06",
            "date": "2021-05-28",
            "duedate": "2021-06-27",
            "currency": "1",
            "subtotal": "110.00",
            "total_tax": "0.00",
            "total": "110.00",
            "adjustment": "0.00",
            "addedfrom": "0",
            "hash": "630f8cc7ed2e6a70c4113ab24041bdf5",
            "status": "6",
            "clientnote": "",
            "adminnote": "",
            "last_overdue_reminder": null,
            "cancel_overdue_reminders": "1",
            "allowed_payment_modes": "a:2:{i:0;s:1:\"1\";i:1;s:1:\"2\";}",
            "token": null,
            "discount_percent": "0.00",
            "discount_total": "0.00",
            "discount_type": "",
            "recurring": "0",
            "recurring_type": null,
            "custom_recurring": "0",
            "cycles": "0",
            "total_cycles": "0",
            "is_recurring_from": null,
            "last_recurring_date": null,
            "terms": "",
            "sale_agent": "0",
            "billing_street": "",
            "billing_city": "",
            "billing_state": "",
            "billing_zip": "",
            "billing_country": "0",
            "shipping_street": "",
            "shipping_city": "",
            "shipping_state": "",
            "shipping_zip": "",
            "shipping_country": "0",
            "include_shipping": "1",
            "show_shipping_on_invoice": "1",
            "show_quantity_as": "1",
            "project_id": "0",
            "subscription_id": "0",
            "short_link": null,
            "userid": "1",
            "company": "updated company",
            "vat": "",
            "phonenumber": "",
            "country": "0",
            "city": "",
            "zip": "",
            "state": "",
            "address": "",
            "website": "",
            "active": "1",
            "leadid": null,
            "longitude": null,
            "latitude": null,
            "default_language": "",
            "default_currency": "0",
            "show_primary_contact": "0",
            "stripe_id": null,
            "registration_confirmed": "1",
            "invoiceid": "2",
            "customfields": [
                {
                    "label": "Input 1",
                    "value": "test 12"
                },
                {
                    "label": "Number 1",
                    "value": "10"
                },
                {
                    "label": "Textarea 1",
                    "value": "Lorem Ipsum is simply dummy text of the printing and typesetting industry"
                },
                {
                    "label": "Select 1",
                    "value": "Option 1"
                },
                {
                    "label": "Multiselect 1",
                    "value": "Option 1, Option 2"
                },
                {
                    "label": "Checkbox 1",
                    "value": "Option 1, Option 3"
                },
                {
                    "label": "Datepicker 1",
                    "value": "2021-05-06"
                },
                {
                    "label": "Datetime Picker 1",
                    "value": "2021-05-06 00:23:25"
                },
                {
                    "label": "Colorpicker 1",
                    "value": "#ffffff"
                },
                {
                    "label": "Hyperlink 1",
                    "value": "<a>Link</a>"
                }
            ]
        }
    ]
HTTP/1.1 404 Not Found
Same as Original request

Custom_Fields – Update Custom Fields

Submit URL for PUT request of the custom fields remains the same for each endpoint (ie api/contacts for Contacts endpoint, api/invoices for Invoices endpoint, etc..)

In this example, we will use the following form data which corresponds to the following custom field types:

custom_fields[invoice][1] = Input Type
custom_fields[invoice][2] = Number
custom_fields[invoice][3] = Textarea
custom_fields[invoice][4] = Radio
custom_fields[invoice][5] = Checkbox
custom_fields[invoice][6] = Multiselect
custom_fields[invoice][7] = Date
custom_fields[invoice][8] = Datetime
custom_fields[invoice][9] = Color
custom_fields[invoice][10] = Link

PUTyourdomain.com/N/A

Parameter

FieldTypeDescription
custom_fields[customFieldType]string/arrayCustom Field JSON should be same as below with field_name and custom_field_id returned from Search custom field values’ information
HTTP/1.1 200 OK
 Same as Original request
HTTP/1.1 404 Not Found
Same as Original request

Customers

Customers – Add New Customer

POSTyourdomain.com/api/customers

Header

FieldTypeDescription
authtokenStringAuthentication token, generated from admin area

Parameter

FieldTypeDescription
companyStringMandatory Customer company.
vat (optional)StringOptional Vat.
phonenumber (optional)StringOptional Customer Phone.
website (optional)StringOptional Customer Website.
groups_in (optional)Number[]Optional Customer groups.
default_language (optional)StringOptional Customer Default Language.
default_currency (optional)StringOptional default currency.
address (optional)StringOptional Customer address.
city (optional)StringOptional Customer City.
state (optional)StringOptional Customer state.
zip (optional)StringOptional Zip Code.
partnership_type (optional)StringOptional Customer partnership type.
country (optional)StringOptional country.
billing_street (optional)StringOptional Billing Address: Street.
billing_city (optional)StringOptional Billing Address: City.
billing_state (optional)NumberOptional Billing Address: State.
billing_zip (optional)StringOptional Billing Address: Zip.
billing_country (optional)StringOptional Billing Address: Country.
shipping_street (optional)StringOptional Shipping Address: Street.
shipping_city (optional)StringOptional Shipping Address: City.
shipping_state (optional)StringOptional Shipping Address: State.
shipping_zip (optional)StringOptional Shipping Address: Zip.
shipping_country (optional)StringOptional Shipping Address: Country.

Success 200

FieldTypeDescription
statusBooleanRequest status.
messageStringCustomer add successful.

Error 4xx

NameTypeDescription
statusBooleanRequest status.
messageStringCustomer add fail.
HTTP/1.1 200 OK
{
  "status": true,
  "message": "Customer add successful."
}
HTTP/1.1 404 Not Found
{
  "status": false,
  "message": "Customer add fail."
}

Customers – Delete a Customer

DELETEyourdomain.com/api/delete/customers/:id

Header

FieldTypeDescription
authtokenStringAuthentication token, generated from admin area

Parameter

FieldTypeDescription
idNumberCustomer unique ID.

Success 200

FieldTypeDescription
statusStringRequest status.
messageStringCustomer Delete Successful.

Error 4xx

NameTypeDescription
statusBooleanRequest status.
messageStringCustomer Delete Fail.
HTTP/1.1 200 OK
{
  "status": true,
  "message": "Customer Delete Successful."
}
HTTP/1.1 404 Not Found
{
  "status": false,
  "message": "Customer Delete Fail."
}

Customers – Request customer information

GETyourdomain.com/api/customers/:id

Header

FieldTypeDescription
authtokenStringAuthentication token, generated from admin area

Parameter

FieldTypeDescription
idNumbercustomer unique ID.

Success 200

FieldTypeDescription
customerObjectinformation.

Error 4xx

NameTypeDescription
statusBooleanRequest status.
messageStringNo data were found.
HTTP/1.1 200 OK
{
     "id": "28",
     "name": "Test1",
     "description": null,
     "status": "1",
     "clientid": "11",
     "billing_type": "3",
     "start_date": "2019-04-19",
     "deadline": "2019-08-30",
     "customer_created": "2019-07-16",
     "date_finished": null,
     "progress": "0",
     "progress_from_tasks": "1",
     "customer_cost": "0.00",
     "customer_rate_per_hour": "0.00",
     "estimated_hours": "0.00",
     "addedfrom": "5",
     "rel_type": "customer",
     "potential_revenue": "0.00",
     "potential_margin": "0.00",
     "external": "E",
    ...
}
HTTP/1.1 404 Not Found
{
  "status": false,
  "message": "No data were found"
}

Customers – Search Customer Information

GETyourdomain.com/api/customers/search/:keysearch

Header

FieldTypeDescription
authtokenStringAuthentication token, generated from admin area

Parameter

FieldTypeDescription
keysearchStringSearch Keywords.

Success 200

FieldTypeDescription
customerObjectinformation.

Error 4xx

NameTypeDescription
statusBooleanRequest status.
messageStringNo data were found.
HTTP/1.1 200 OK
{
     "id": "28",
     "name": "Test1",
     "description": null,
     "status": "1",
     "clientid": "11",
     "billing_type": "3",
     "start_date": "2019-04-19",
     "deadline": "2019-08-30",
     "customer_created": "2019-07-16",
     "date_finished": null,
     "progress": "0",
     "progress_from_tasks": "1",
     "customer_cost": "0.00",
     "customer_rate_per_hour": "0.00",
     "estimated_hours": "0.00",
     "addedfrom": "5",
     "rel_type": "customer",
     "potential_revenue": "0.00",
     "potential_margin": "0.00",
     "external": "E",
    ...
}
HTTP/1.1 404 Not Found
{
  "status": false,
  "message": "No data were found"
}

Customers – Update a Customer

PUTyourdomain.com/api/customers/:id

Header

FieldTypeDescription
authtokenStringAuthentication token, generated from admin area

Parameter

FieldTypeDescription
companyStringMandatory Customer company.
vat (optional)StringOptional Vat.
phonenumber (optional)StringOptional Customer Phone.
website (optional)StringOptional Customer Website.
groups_in (optional)Number[]Optional Customer groups.
default_language (optional)StringOptional Customer Default Language.
default_currency (optional)StringOptional default currency.
address (optional)StringOptional Customer address.
city (optional)StringOptional Customer City.
state (optional)StringOptional Customer state.
zip (optional)StringOptional Zip Code.
country (optional)StringOptional country.
billing_street (optional)StringOptional Billing Address: Street.
billing_city (optional)StringOptional Billing Address: City.
billing_state (optional)NumberOptional Billing Address: State.
billing_zip (optional)StringOptional Billing Address: Zip.
billing_country (optional)StringOptional Billing Address: Country.
shipping_street (optional)StringOptional Shipping Address: Street.
shipping_city (optional)StringOptional Shipping Address: City.
shipping_state (optional)StringOptional Shipping Address: State.
shipping_zip (optional)StringOptional Shipping Address: Zip.
shipping_country (optional)StringOptional Shipping Address: Country.

Success 200

FieldTypeDescription
statusBooleanRequest status.
messageStringCustomer Update Successful.

Error 4xx

NameTypeDescription
statusBooleanRequest status.
messageStringCustomer Update Fail.
HTTP/1.1 200 OK
{
  "status": true,
  "message": "Customer Update Successful."
}
HTTP/1.1 404 Not Found
{
  "status": false,
  "message": "Customer Update Fail."
}

Estimates

Estimates – Add New Estimates

POSTyourdomain.com/api/estimates

Header

FieldTypeDescription
authtokenStringAuthentication token, generated from admin area

Parameter

FieldTypeDescription
clientidNumberMandatory. Customer id
numberNumberMandatory. Estimates Number
dateDateMandatory. Estimates Date
duedate (optional)DateOptional. Expiry Date of Estimates
currencyNumberMandatory. currency field
newitemsArrayMandatory. New Items to be added
subtotalDecimalMandatory. calculation based on item Qty, Rate and Tax
totalDecimalMandatory. calculation based on subtotal, Discount and Adjustment
billing_streetStringOptional. Street Address
billing_city (optional)StringOptional. City Name for billing
billing_state (optional)StringOptional. Name of state for billing
billing_zip (optional)NumberOptional. Zip code
billing_country (optional)NumberOptional. Country code
shipping_street (optional)StringOptional. Address of shipping
shipping_city (optional)StringOptional. City name for shipping
shipping_state (optional)StringOptional. Name of state for shipping
shipping_zip (optional)NumberOptional. Zip code for shipping
shipping_country (optional)NumberOptional. Country code
tags (optional)StringOptional. TAGS comma separated
status (optional)NumberOptional. Status id (default status is Accepted)
Reference (optional)StringOptional. Reference name
sale_agent (optional)NumberOptional. Sale Agent name
adminnote (optional)StringOptional. notes by admin
clientnote (optional)StringOptional. client notes
terms (optional)StringOptional. Terms

Success 200

FieldTypeDescription
statusBooleanRequest status.
messageStringEstimates Added Successfully

Error 4xx

NameTypeDescription
statusBooleanRequest status.
messageStringEstimates add fail
newitems[]StringThe Items field is required
numberStringThe Estimates number is already in use
subtotalStringThe Sub Total field is required
totalStringThe Total field is required
HTTP/1.1 200 OK
{
  "status": true,
  "message": "Estimates Added Successfully"
}
HTTP/1.1 404 Not Found
{
  "status": false,
  "message": "Estimates Add Fail"
}

Estimates – Delete Estimate

DELETEyourdomain.com/api/estimates/:id

Header

FieldTypeDescription
authtokenStringAuthentication token, generated from admin area

Success 200

FieldTypeDescription
statusBooleanRequest status.
messageStringEstimates Deleted Successfully

Error 4xx

NameTypeDescription
statusBooleanRequest status.
messageStringEstimate Delete Fail
HTTP/1.1 200 OK
{
  "status": true,
  "message": "Estimate Deleted Successfully"
}
HTTP/1.1 404 Not Found
{
  "status": false,
  "message": "Estimate Delete Fail"
}

Estimates – Request Estimate information

GETyourdomain.com/api/estimates/:id

Header

FieldTypeDescription
authtokenStringAuthentication token, generated from admin area

Parameter

FieldTypeDescription
idNumberContact unique ID

Success 200

FieldTypeDescription
EstimatesObjectinformation.

Error 4xx

NameTypeDescription
statusBooleanRequest status.
messageStringNo data were found.
  HTTP/1.1 200 OK
  {
	    "id": "1",
	    "sent": "0",
	    "datesend": null,
	    "clientid": "1",
	    "deleted_customer_name": null,
	    "project_id": "0",
	    "number": "1",
	    "prefix": "EST-",
	    "number_format": "1",
	    "hash": "b12ae9de6471d0cf153d7846f05128af",
	    "datecreated": "2021-07-31 11:06:49",
	    "date": "2021-07-31",
	    "expirydate": "2021-08-07",
	    "currency": "1",
	    "subtotal": "1200.00",
	    "total_tax": "0.00",
	    "total": "1200.00",
	    "adjustment": "0.00",
	    "addedfrom": "1",
	    "status": "1",
	    "clientnote": "",
	    "adminnote": "",
	    "discount_percent": "0.00",
	    "discount_total": "0.00",
	    "discount_type": "",
	    "invoiceid": null,
	    "invoiced_date": null,
	    "terms": "",
	    "reference_no": "",
	    "sale_agent": "0",
	    "billing_street": "Thangadh, Gujarat, India<br />\r\nShipping",
	    "billing_city": "Thangadh",
	    "billing_state": "Gujarat",
	    "billing_zip": "363630",
	    "billing_country": "102",
	    "shipping_street": "Thangadh, Gujarat, India<br />\r\nShipping",
	    "shipping_city": "Thangadh",
	    "shipping_state": "Gujarat",
	    "shipping_zip": "363630",
	    "shipping_country": "102",
	    "include_shipping": "1",
	    "show_shipping_on_estimate": "1",
	    "show_quantity_as": "1",
	    "pipeline_order": "0",
	    "is_expiry_notified": "0",
	    "acceptance_firstname": null,
	    "acceptance_lastname": null,
	    "acceptance_email": null,
	    "acceptance_date": null,
	    "acceptance_ip": null,
	    "signature": null,
	    "short_link": null,
	    "symbol": "$",
	    "name": "USD",
	    "decimal_separator": ".",
	    "thousand_separator": ",",
	    "placement": "before",
	    "isdefault": "1",
	    "currencyid": "1",
	    "currency_name": "USD",
	    "attachments": [],
	    "visible_attachments_to_customer_found": false,
	    "items": [
	        {
	            "id": "2",
	            "rel_id": "1",
	            "rel_type": "estimate",
	            "description": "test",
	            "long_description": "test",
	            "qty": "1.00",
	            "rate": "1200.00",
	            "unit": "1",
	            "item_order": "1"
	        }
	    ],
	    "client": {
	        "userid": "1",
	        "company": "test",
	        "vat": "",
	        "phonenumber": "01324568903",
	        "country": "102",
	        "city": "test",
	        "zip": "3000",
	        "state": "Test",
	        "address": "Test",
	        "website": "",
	        "datecreated": "2021-07-30 16:29:46",
	        "active": "1",
	        "leadid": null,
	        "billing_street": "Test",
	        "billing_city": "Test",
	        "billing_state": "Test",
	        "billing_zip": "3000",
	        "billing_country": "102",
	        "shipping_street": "Test",
	        "shipping_city": "Test",
	        "shipping_state": "Test",
	        "shipping_zip": "3000",
	        "shipping_country": "102",
	        "longitude": null,
	        "latitude": null,
	        "default_language": "",
	        "default_currency": "0",
	        "show_primary_contact": "0",
	        "stripe_id": null,
	        "registration_confirmed": "1",
	        "addedfrom": "1"
	    },
	    "scheduled_email": null,
	    "customfields": []
	}
HTTP/1.1 404 Not Found
{
  "status": false,
  "message": "No data were found"
}

Estimates – Search Estimate information

GETyourdomain.com/api/estimates/search/:keysearch

Header

FieldTypeDescription
authtokenStringAuthentication token, generated from admin area

Parameter

FieldTypeDescription
keysearchStringSearch Keywords.

Success 200

FieldTypeDescription
EstimateObjectInformation.

Error 4xx

NameTypeDescription
statusBooleanRequest status.
messageStringNo data were found.
HTTP/1.1 200 OK
 {
    "id": "2",
    "sent": "0",
    "datesend": null,
    "clientid": "1",
    "deleted_customer_name": null,
    "project_id": "0",
    "number": "2",
    "prefix": "EST-",
    "number_format": "1",
    "hash": "ac754972999f948ade369c70bb44d696",
    "datecreated": "2021-07-30 16:29:46",
    "date": "2021-08-01",
    "expirydate": "2021-08-08",
    "currency": "1",
    "subtotal": "1200.00",
    "total_tax": "0.00",
    "total": "1200.00",
    "adjustment": "0.00",
    "addedfrom": "1",
    "status": "1",
    "clientnote": "",
    "adminnote": "adminnote",
    "discount_percent": "0.00",
    "discount_total": "0.00",
    "discount_type": "",
    "invoiceid": null,
    "invoiced_date": null,
    "terms": "",
    "reference_no": "",
    "sale_agent": "0",
    "billing_street": "Test",
    "billing_city": "Test",
    "billing_state": "Test",
    "billing_zip": "3000",
    "billing_country": "102",
    "shipping_street": "Test",
    "shipping_city": "Test",
    "shipping_state": "Test",
    "shipping_zip": "3000",
    "shipping_country": "102",
    "include_shipping": "1",
    "show_shipping_on_estimate": "1",
    "show_quantity_as": "1",
    "pipeline_order": "0",
    "is_expiry_notified": "0",
    "acceptance_firstname": null,
    "acceptance_lastname": null,
    "acceptance_email": null,
    "acceptance_date": null,
    "acceptance_ip": null,
    "signature": null,
    "short_link": null,
    "userid": "1",
    "company": "test",
    "vat": "",
    "phonenumber": "01324568903",
    "country": "102",
    "city": "Test",
    "zip": "3000",
    "state": "Test",
    "address": "Test",
    "website": "",
    "active": "1",
    "leadid": null,
    "longitude": null,
    "latitude": null,
    "default_language": "",
    "default_currency": "0",
    "show_primary_contact": "0",
    "stripe_id": null,
    "registration_confirmed": "1",
    "estimateid": "2",
   "customfields": []
}
HTTP/1.1 404 Not Found
{
  "status": false,
  "message": "No Data Were Found"
}

Estimates – Update a estimate

PUTyourdomain.com/api/estimates/:id

Header

FieldTypeDescription
authtokenStringAuthentication token, generated from admin area

Parameter

FieldTypeDescription
clientidStringMandatory. Customer.
billing_streetStringMandatory. Street Address
billing_city (optional)StringOptional. City Name for billing
billing_state (optional)StringOptional. Name of state for billing
billing_zip (optional)NumberOptional. Zip code
billing_country (optional)NumberOptional. Country code
include_shipping (optional)booleanOptional. set yes if you want add Shipping AddressDefault value: no
show_shipping_on_estimate (optional)booleanOptional. Shows shipping details in estimate.
shipping_street (optional)StringOptional. Address of shipping
shipping_city (optional)StringOptional. City name for shipping
shipping_state (optional)StringOptional. Name of state for shipping
shipping_zip (optional)NumberOptional. Zip code for shipping
shipping_country (optional)NumberOptional. Country code
numberNumberMandatory. Estimate Number
dateDateMandatory. Estimate Date
expirydate (optional)DateOptional. Expiry Date of Estimate
tags (optional)StringOptional. TAGS comma separated
currencyNumberMandatory. currency field
statusNumberMandatory. Estimate Status(eg. Draft, Sent)
reference_no (optional)StringOptional. Reference #
sale_agent (optional)NumberOptional. Sale Agent name
discount_type (optional)StringOptional. before_tax / after_tax discount type
adminnote (optional)StringOptional. notes by admin
items (optional)ArrayMandatory. Existing items with Id
removed_items (optional)ArrayOptional. Items to be removed
newitems (optional)ArrayOptional. New Items to be added
subtotalDecimalMandatory. calculation based on item Qty, Rate and Tax
totalDecimalMandatory. calculation based on subtotal, Discount and Adjustment
clientnote (optional)StringOptional. client notes
terms (optional)StringOptional. Terms

Error 4xx

NameTypeDescription
numberStringThe Estimate number is already in use
HTTP/1.1 200 OK
{
  "status": false,
  "message": "Estimate Updated Successfully"
}
HTTP/1.1 404 Not Found
{
  "status": false,
  "message": "Estimate Update Fail"
}

Expense Categories

Expense_Categories – Request Expense category

GETyourdomain.com/api/common/expense_category

Header

FieldTypeDescription
authtokenStringAuthentication token, generated from admin area

Success 200

FieldTypeDescription
ExpenseArraycategory information.

Error 4xx

NameTypeDescription
statusBooleanRequest status.
messageStringNo data were found.
HTTP/1.1 200 OK
{

   [
       {
           "id": "1",
           "name": "cloud server",
           "description": "AWS server"
       },
       {
           "id": "2",
           "name": "website domain",
           "description": "domain Managment and configurations"
       }
   ]

}
HTTP/1.1 404 Not Found
{
  "status": false,
  "message": "No data were found"
}

Expenses

Expenses – Add Expense

POSTyourdomain.com/api/expenses

Header

FieldTypeDescription
authtokenStringAuthentication token, generated from admin area

Parameter

FieldTypeDescription
expense_name (optional)StringOptional. Expanse Name
note (optional)StringOptional. Expanse Note
categoryNumberMandatory. Expense Category
amountDecimalMandatory. Expense Amount
dateDateMandatory. Expense Date
clientidNumberOptional. Customer id
currencyNumberMandatory. Currency Field
taxNumberOptional. Tax 1
tax2NumberOptional. Tax 2
paymentmodeNumberOptional. Payment mode
reference_no (optional)StringOptional. Reference #
recurring (optional)StringOptional. recurring 1 to 12 or custom
repeat_every_custom (optional)NumberOptional. if recurring is custom set number gap
repeat_type_custom (optional)StringOptional. if recurring is custom set gap option day/week/month/year

Success 200

FieldTypeDescription
statusBooleanRequest status.
messageStringExpense Added Successfully

Error 4xx

NameTypeDescription
statusBooleanRequest status.
messageStringExpense Update Fail
categoryStringThe Expense Category is not found.
dateStringThe Expense date field is required.
amountStringThe Amount field is required.
HTTP/1.1 200 OK
{
  "status": true,
  "message": "Expense Added Successfully"
}
HTTP/1.1 404 Not Found
{
  "status": false,
  "message": "Expense Add Fail"
}

Expenses – Delete Expense

DELETEyourdomain.com/api/expenses/:id

Header

FieldTypeDescription
authtokenStringAuthentication token, generated from admin area

Success 200

FieldTypeDescription
statusBooleanRequest status.
messageStringExpense Deleted Successfully

Error 4xx

NameTypeDescription
statusBooleanRequest status.
messageStringExpense Delete Fail
HTTP/1.1 200 OK
{
  "status": true,
  "message": "Expense Deleted Successfully"
}
HTTP/1.1 404 Not Found
{
  "status": false,
  "message": "Expense Delete Fail"
}

Expenses – Request Expense information

GETyourdomain.com/api/expenses/:id

Header

FieldTypeDescription
authtokenStringAuthentication token, generated from admin area

Parameter

FieldTypeDescription
idNumberExpense unique ID.

Success 200

FieldTypeDescription
ExpenseArrayExpense information.

Error 4xx

NameTypeDescription
statusBooleanRequest status.
messageStringNo data were found.
[
    {
        "id": "1",
        "category": "1",
        "currency": "1",
        "amount": "50.00",
        "tax": "0",
        "tax2": "0",
        "reference_no": "012457893",
        "note": "AWS server hosting charges",
        "expense_name": "Cloud Hosting",
        "clientid": "1",
        "project_id": "0",
        "billable": "0",
        "invoiceid": null,
        "paymentmode": "2",
        "date": "2021-09-01",
        "recurring_type": "month",
        "repeat_every": "1",
        "recurring": "1",
        "cycles": "12",
        "total_cycles": "0",
        "custom_recurring": "0",
        "last_recurring_date": null,
        "create_invoice_billable": "0",
        "send_invoice_to_customer": "0",
        "recurring_from": null,
        "dateadded": "2021-09-01 12:26:34",
        "addedfrom": "1",
        "is_expense_created_in_xero": "0",
        "userid": "1",
        "company": "Company A",
        "vat": "",
        "phonenumber": "",
        "country": "0",
        "city": "",
        "zip": "",
        "state": "",
        "address": "",
        "website": "",
        "datecreated": "2020-05-25 22:55:49",
        "active": "1",
        "leadid": null,
        "billing_street": "",
        "billing_city": "",
        "billing_state": "",
        "billing_zip": "",
        "billing_country": "0",
        "shipping_street": "",
        "shipping_city": "",
        "shipping_state": "",
        "shipping_zip": "",
        "shipping_country": "0",
        "longitude": null,
        "latitude": null,
        "default_language": "",
        "default_currency": "0",
        "show_primary_contact": "0",
        "stripe_id": null,
        "registration_confirmed": "1",
        "name": "Hosting Management",
        "description": "server space and other settings",
        "show_on_pdf": "0",
        "invoices_only": "0",
        "expenses_only": "0",
        "selected_by_default": "0",
        "taxrate": null,
        "category_name": "Hosting Management",
        "payment_mode_name": "Paypal",
        "tax_name": null,
        "tax_name2": null,
        "taxrate2": null,
        "expenseid": "1",
        "customfields": []
    }
]
HTTP/1.1 404 Not Found
{
  "status": false,
  "message": "No data were found"
}

Expenses – Search Expenses information

GETyourdomain.com/api/expenses/search/:keysearch

Header

FieldTypeDescription
authtokenStringAuthentication token, generated from admin area

Parameter

FieldTypeDescription
keysearchStringSearch Keywords

Success 200

FieldTypeDescription
ExpensesArrayExpenses Information

Error 4xx

NameTypeDescription
statusBooleanRequest status
messageStringNo data were found
[
    {
        "id": "1",
        "category": "1",
        "currency": "1",
        "amount": "50.00",
        "tax": "0",
        "tax2": "0",
        "reference_no": "012457893",
        "note": "AWS server hosting charges",
        "expense_name": "Cloud Hosting",
        "clientid": "1",
        "project_id": "0",
        "billable": "0",
        "invoiceid": null,
        "paymentmode": "2",
        "date": "2021-09-01",
        "recurring_type": "month",
        "repeat_every": "1",
        "recurring": "1",
        "cycles": "12",
        "total_cycles": "0",
        "custom_recurring": "0",
        "last_recurring_date": null,
        "create_invoice_billable": "0",
        "send_invoice_to_customer": "0",
        "recurring_from": null,
        "dateadded": "2021-09-01 12:26:34",
        "addedfrom": "1",
        "is_expense_created_in_xero": "0",
        "userid": "1",
        "company": "Company A",
        "vat": "",
        "phonenumber": "",
        "country": "0",
        "city": "",
        "zip": "",
        "state": "",
        "address": "",
        "website": "",
        "datecreated": "2020-05-25 22:55:49",
        "active": "1",
        "leadid": null,
        "billing_street": "",
        "billing_city": "",
        "billing_state": "",
        "billing_zip": "",
        "billing_country": "0",
        "shipping_street": "",
        "shipping_city": "",
        "shipping_state": "",
        "shipping_zip": "",
        "shipping_country": "0",
        "longitude": null,
        "latitude": null,
        "default_language": "",
        "default_currency": "0",
        "show_primary_contact": "0",
        "stripe_id": null,
        "registration_confirmed": "1",
        "name": "Hosting Management",
        "description": "server space and other settings",
        "show_on_pdf": "0",
        "invoices_only": "0",
        "expenses_only": "0",
        "selected_by_default": "0",
        "taxrate": null,
        "category_name": "Hosting Management",
        "payment_mode_name": "Paypal",
        "tax_name": null,
        "tax_name2": null,
        "taxrate2": null,
        "expenseid": "1",
        "customfields": []
    }
]
HTTP/1.1 404 Not Found
{
  "status": false,
  "message": "No data were found"
}

Expenses – Update a Expense

PUTyourdomain.com/api/expenses

Header

FieldTypeDescription
authtokenStringAuthentication token, generated from admin area

Parameter

FieldTypeDescription
expense_name (optional)StringOptional. Name
note (optional)StringOptional. Note
categoryNumberMandatory. Expense Category
amountDecimalMandatory. Expense Amount
dateDateMandatory. Expense Date
clientidNumberOptional. Customer id
currencyNumberMandatory. currency field
taxNumberOptional. Tax 1
tax2NumberOptional. Tax 2
paymentmodeNumberOptional. Payment mode
reference_no (optional)StringOptional. Reference #
recurring (optional)StringOptional. recurring 1 to 12 or custom
repeat_every_custom (optional)NumberOptional. if recurring is custom set number gap
repeat_type_custom (optional)StringOptional. if recurring is custom set gap option day/week/month/year

Success 200

FieldTypeDescription
statusBooleanRequest status.
messageStringExpense Updated Successfully

Error 4xx

NameTypeDescription
statusBooleanRequest status.
messageStringExpense Update Fail
categoryStringThe Expense Category is not found.
dateStringThe Expense date field is required.
amountStringThe Amount field is required.
HTTP/1.1 200 OK
{
  "status": true,
  "message": "Expense Updated Successfully"
}
HTTP/1.1 404 Not Found
{
  "status": false,
  "message": "Expense Update Fail"
}

Invoices

Invoices – Add New invoice

POSTyourdomain.com/api/invoices

Header

FieldTypeDescription
authtokenStringAuthentication token, generated from admin area

Parameter

FieldTypeDescription
clientidNumberMandatory. Customer id
numberNumberMandatory. Invoice Number
dateDateMandatory. Invoice Date
currencyNumberMandatory. currency field
newitemsArrayMandatory. New Items to be added
subtotalDecimalMandatory. calculation based on item Qty, Rate and Tax
totalDecimalMandatory. calculation based on subtotal, Discount and Adjustment
billing_streetStringMandatory. Street Address
allowed_payment_modesArrayMandatory. Payment modes
billing_city (optional)StringOptional. City Name for billing
billing_state (optional)StringOptional. Name of state for billing
billing_zip (optional)NumberOptional. Zip code
billing_country (optional)NumberOptional. Country code
include_shipping (optional)booleanOptional. set yes if you want add Shipping AddressDefault value: no
show_shipping_on_invoice (optional)booleanOptional. Shows shipping details in invoice.
shipping_street (optional)StringOptional. Address of shipping
shipping_city (optional)StringOptional. City name for shipping
shipping_state (optional)StringOptional. Name of state for shipping
shipping_zip (optional)NumberOptional. Zip code for shipping
shipping_country (optional)NumberOptional. Country code
duedate (optional)DateOptional. Due date for Invoice
cancel_overdue_reminders (optional)booleanOptional. Prevent sending overdue remainders for invoice
tags (optional)StringOptional. TAGS comma separated
sale_agent (optional)NumberOptional. Sale Agent name
recurring (optional)StringOptional. recurring 1 to 12 or custom
discount_type (optional)StringOptional. before_tax / after_tax discount type
repeat_every_custom (optional)NumberOptional. if recurring is custom set number gap
repeat_type_custom (optional)StringOptional. if recurring is custom set gap option day/week/month/year
cycles (optional)NumberOptional. number of cycles 0 for infinite
adminnote (optional)StringOptional. notes by admin
removed_items (optional)ArrayOptional. Items to be removed
clientnote (optional)StringOptional. client notes
terms (optional)StringOptional. Terms

Success 200

FieldTypeDescription
statusBooleanRequest status.
messageStringInvoice Added Successfully

Error 4xx

NameTypeDescription
statusBooleanRequest status.
messageStringInvoice add fail
newitems[]StringThe Items field is required
numberStringThe Invoice number is already in use
allowed_payment_modes[]StringThe Allow Payment Mode field is required
billing_streetStringThe Billing Street field is required
subtotalStringThe Sub Total field is required
totalStringThe Total field is required
HTTP/1.1 200 OK
{
  "status": true,
  "message": "Invoice Added Successfully"
}
HTTP/1.1 404 Not Found
{
  "status": false,
  "message": "Invoice Add Fail"
}

Invoices – Delete invoice

DELETEyourdomain.com/api/invoices/:id

Header

FieldTypeDescription
authtokenStringAuthentication token, generated from admin area

Success 200

FieldTypeDescription
statusBooleanRequest status.
messageStringInvoice Deleted Successfully

Error 4xx

NameTypeDescription
statusBooleanRequest status.
messageStringInvoice Delete Fail
HTTP/1.1 200 OK
{
  "status": true,
  "message": "Invoice Deleted Successfully"
}
HTTP/1.1 404 Not Found
{
  "status": false,
  "message": "Invoice Delete Fail"
}

Invoices – Request invoice information

GETyourdomain.com/api/invoices/:id

Header

FieldTypeDescription
authtokenStringAuthentication token, generated from admin area

Parameter

FieldTypeDescription
idNumberContact unique ID

Success 200

FieldTypeDescription
InvoiceObjectInvoice information.

Error 4xx

NameTypeDescription
statusBooleanRequest status.
messageStringNo data were found.
  HTTP/1.1 200 OK
  {
      "id": "2",
      "sent": "0",
      "datesend": null,
      "clientid": "1",
      "deleted_customer_name": null,
      "number": "2",
      "prefix": "INV-",
      "number_format": "1",
      "datecreated": "2020-05-26 19:53:11",
      "date": "2020-05-26",
      "duedate": "2020-06-25",
      "currency": "1",
      "subtotal": "5.00",
      "total_tax": "0.00",
      "total": "5.00",
      "adjustment": "0.00",
      "addedfrom": "0",
      "hash": "7bfac86da004df5364407574d4d1dbf2",
      "status": "1",
      "clientnote": null,
      "adminnote": null,
      "last_overdue_reminder": null,
      "cancel_overdue_reminders": "0",
      "allowed_payment_modes": "['1']",
      "token": null,
      "discount_percent": "0.00",
      "discount_total": "0.00",
      "discount_type": "",
      "recurring": "0",
      "recurring_type": null,
      "custom_recurring": "0",
      "cycles": "0",
      "total_cycles": "0",
      "is_recurring_from": null,
      "last_recurring_date": null,
      "terms": null,
      "sale_agent": "0",
      "billing_street": "",
      "billing_city": "",
      "billing_state": "",
      "billing_zip": "",
      "billing_country": null,
      "shipping_street": null,
      "shipping_city": null,
      "shipping_state": null,
      "shipping_zip": null,
      "shipping_country": null,
      "include_shipping": "0",
      "show_shipping_on_invoice": "1",
      "show_quantity_as": "1",
      "project_id": "0",
      "subscription_id": "0",
      "symbol": "$",
      "name": "USD",
      "decimal_separator": ".",
      "thousand_separator": ",",
      "placement": "before",
      "isdefault": "1",
      "currencyid": "1",
      "currency_name": "USD",
      "total_left_to_pay": "5.00",
      "items": [
       {
          "id": "2",
          "rel_id": "2",
          "rel_type": "invoice",
          "description": "12MP Dual Camera with cover",
          "long_description": "The JBL Cinema SB110 is a hassle-free soundbar",
          "qty": "1.00",
          "rate": "5.00",
          "unit": "",
          "item_order": "1"
          }
      ],
      "attachments": [],
      "visible_attachments_to_customer_found": false,
      "client": {
      "userid": "1",
      "company": "trueline",
      "vat": "",
      "phonenumber": "",
      "country": "0",
      "city": "",
      "zip": "",
      "state": "",
      "address": "",
      "website": "",
      "datecreated": "2020-05-19 20:07:49",
      "active": "1",
      "leadid": null,
      "billing_street": "",
      "billing_city": "",
      "billing_state": "",
      "billing_zip": "",
      "billing_country": "0",
      "shipping_street": "",
      "shipping_city": "",
      "shipping_state": "",
      "shipping_zip": "",
      "shipping_country": "0",
      "longitude": null,
      "latitude": null,
      "default_language": "english",
      "default_currency": "0",
      "show_primary_contact": "0",
      "stripe_id": null,
      "registration_confirmed": "1",
      "addedfrom": "1"
  },
  "payments": [],
  "scheduled_email": null
}
HTTP/1.1 404 Not Found
{
  "status": false,
  "message": "No data were found"
}

Invoices – Search invoice information

GETyourdomain.com/api/invoices/search/:keysearch

Header

FieldTypeDescription
authtokenStringAuthentication token, generated from admin area

Parameter

FieldTypeDescription
keysearchStringSearch Keywords.

Success 200

FieldTypeDescription
InvoiceObjectInformation.

Error 4xx

NameTypeDescription
statusBooleanRequest status.
messageStringNo data were found.
HTTP/1.1 200 OK
  {
      "id": "19",
      "sent": "0",
      "datesend": null,
      "clientid": "3",
      "deleted_customer_name": null,
      "number": "19",
      "prefix": "INV-",
      "number_format": "1",
      "datecreated": "2020-08-18 21:19:51",
      "date": "2020-07-04",
      "duedate": "2020-08-03",
      "currency": "1",
      "subtotal": "20.00",
      "total_tax": "1.80",
      "total": "21.80",
      "adjustment": "0.00",
      "addedfrom": "1",
      "hash": "809c0e4c9efba2a3bedfdb5871dc6240",
      "status": "2",
      "clientnote": "",
      "adminnote": "",
      "last_overdue_reminder": null,
      "cancel_overdue_reminders": "0",
      "allowed_payment_modes": "['1']",
      "token": null,
      "discount_percent": "0.00",
      "discount_total": "0.00",
      "discount_type": "",
      "recurring": "0",
      "recurring_type": null,
      "custom_recurring": "0",
      "cycles": "0",
      "total_cycles": "0",
      "is_recurring_from": null,
      "last_recurring_date": null,
      "terms": "",
      "sale_agent": "0",
      "billing_street": "",
      "billing_city": "",
      "billing_state": "",
      "billing_zip": "",
      "billing_country": "0",
      "shipping_street": "",
      "shipping_city": "",
      "shipping_state": "",
      "shipping_zip": "",
      "shipping_country": "0",
      "include_shipping": "0",
      "show_shipping_on_invoice": "1",
      "show_quantity_as": "1",
      "project_id": "0",
      "subscription_id": "0",
      "userid": "3",
      "company": "xyz",
      "vat": "",
      "phonenumber": "",
      "country": "0",
      "city": "",
      "zip": "",
      "state": "",
      "address": "",
      "website": "",
      "active": "1",
      "leadid": null,
      "longitude": null,
      "latitude": null,
      "default_language": "",
      "default_currency": "0",
      "show_primary_contact": "0",
      "stripe_id": null,
      "registration_confirmed": "1",
      "invoiceid": "19"
  }
HTTP/1.1 404 Not Found
{
  "status": false,
  "message": "No Data Were Found"
}

Invoices – Update invoice

PUTyourdomain.com/api/invoices/:id

Header

FieldTypeDescription
authtokenStringAuthentication token, generated from admin area

Parameter

FieldTypeDescription
clientidNumberMandatory Customer id.
numberNumberMandatory. Invoice Number
dateDateMandatory. Invoice Date
currencyNumberMandatory. currency field
newitemsArrayMandatory. New Items to be added
subtotalDecimalMandatory. calculation based on item Qty, Rate and Tax
totalDecimalMandatory. calculation based on subtotal, Discount and Adjustment
billing_streetStringMandatory. Street Address
allowed_payment_modesArrayMandatory. Payment modes
billing_city (optional)StringOptional. City Name for billing
billing_state (optional)StringOptional. Name of state for billing
billing_zip (optional)NumberOptional. Zip code
billing_country (optional)NumberOptional. Country code
include_shipping (optional)booleanOptional. set yes if you want add Shipping AddressDefault value: no
show_shipping_on_invoice (optional)booleanOptional. Shows shipping details in invoice.
shipping_street (optional)StringOptional. Address of shipping
shipping_city (optional)StringOptional. City name for shipping
shipping_state (optional)StringOptional. Name of state for shipping
shipping_zip (optional)NumberOptional. Zip code for shipping
shipping_country (optional)NumberOptional. Country code
duedate (optional)DateOptional. Due date for Invoice
cancel_overdue_reminders (optional)booleanOptional. Prevent sending overdue remainders for invoice
tags (optional)StringOptional. TAGS comma separated
sale_agent (optional)NumberOptional. Sale Agent name
recurring (optional)StringOptional. recurring 1 to 12 or custom
discount_type (optional)StringOptional. before_tax / after_tax discount type
repeat_every_custom (optional)NumberOptional. if recurring is custom set number gap
repeat_type_custom (optional)StringOptional. if recurring is custom set gap option day/week/month/year
cycles (optional)NumberOptional. number of cycles 0 for infinite
adminnote (optional)StringOptional. notes by admin
items (optional)ArrayOptional. Existing items with Id
removed_items (optional)ArrayOptional. Items to be removed
clientnote (optional)StringOptional. client notes
terms (optional)StringOptional. Terms

Error 4xx

NameTypeDescription
numberStringThe Invoice number is already in use
HTTP/1.1 200 OK
{
  "status": false,
  "message": "Invoice Updated Successfully"
}
HTTP/1.1 404 Not Found
{
  "status": false,
  "message": "Invoice Update Fail"
}

Items

Items – Create New Item

POSTyourdomain.com/api/items

Header

FieldTypeDescription
authtokenStringAuthentication token, generated from admin area

Parameter

FieldTypeDescription
descriptionStringMandatory item description/name
rateNumberMandatory item rate/price
long_description (optional)StringOptional long description
tax (optional)NumberOptional primary tax ID
tax2 (optional)NumberOptional secondary tax ID
group_id (optional)NumberOptional item group ID (default: 0)
unit (optional)StringOptional unit of measurement

Success 200

FieldTypeDescription
statusBooleanRequest status
messageStringItem created successfully
item_idNumberThe ID of the newly created item

Error 4xx

NameTypeDescription
statusBooleanRequest status
messageStringItem creation failed
HTTP/1.1 200 OK
{
  "status": true,
  "message": "Item created successfully",
  "item_id": 123
}
HTTP/1.1 404 Not Found
{
  "status": false,
  "message": "Item creation failed"
}

Items – Delete an Item

DELETEyourdomain.com/api/delete/items/:id

Header

FieldTypeDescription
authtokenStringAuthentication token, generated from admin area

Parameter

FieldTypeDescription
idNumberItem unique ID

Success 200

FieldTypeDescription
statusBooleanRequest status
messageStringItem deleted successfully

Error 4xx

NameTypeDescription
statusBooleanRequest status
messageStringItem deletion failed
HTTP/1.1 200 OK
{
  "status": true,
  "message": "Item deleted successfully"
}
HTTP/1.1 404 Not Found
{
  "status": false,
  "message": "Item deletion failed"
}

Items – Request Item information

GETyourdomain.com/api/items/:id

Header

FieldTypeDescription
authtokenStringAuthentication token, generated from admin area

Parameter

FieldTypeDescription
id (optional)NumberOptional Item unique ID. If not provided, returns all items

Success 200

FieldTypeDescription
ItemObjectitem information.

Error 4xx

NameTypeDescription
statusBooleanRequest status.
messageStringNo data were found.
    HTTP/1.1 200 OK
    {
	      "id": "1",
       "description": "JBL Soundbar",
       "long_description": "The JBL Cinema SB110 is a hassle-free soundbar",
       "rate": "100.00",
       "tax": 1,
       "tax2": 2,
       "unit": "pcs",
       "group_id": 0
    }
HTTP/1.1 404 Not Found
{
  "status": false,
  "message": "No data were found"
}

Items – Search Items

GETyourdomain.com/api/items/search/:keysearch

Header

FieldTypeDescription
authtokenStringAuthentication token, generated from admin area

Parameter

FieldTypeDescription
keysearchStringSearch Keywords

Success 200

FieldTypeDescription
ItemObjectItem Information

Error 4xx

NameTypeDescription
statusBooleanRequest status
messageStringNo data were found
HTTP/1.1 200 OK
{
  "data": [
    {
      "id": "1",
      "description": "JBL Soundbar",
      "rate": "100.00",
      ...
    }
  ],
  "meta": {
    "current_page": 1,
    "per_page": 20,
    "total": 45,
    "last_page": 3
  }
}
HTTP/1.1 404 Not Found
{
  "status": false,
  "message": "No data were found"
}

Items – Update an Item

PUTyourdomain.com/api/items/:id

Header

FieldTypeDescription
authtokenStringAuthentication token, generated from admin area

Parameter

FieldTypeDescription
idNumberItem unique ID (in URL)
description (optional)StringOptional item description/name
rate (optional)NumberOptional item rate/price
long_description (optional)StringOptional long description
tax (optional)NumberOptional primary tax ID
tax2 (optional)NumberOptional secondary tax ID
group_id (optional)NumberOptional item group ID
unit (optional)StringOptional unit of measurement

Success 200

FieldTypeDescription
statusBooleanRequest status
messageStringItem updated successfully

Error 4xx

NameTypeDescription
statusBooleanRequest status
messageStringItem update failed
HTTP/1.1 200 OK
{
  "status": true,
  "message": "Item updated successfully"
}
HTTP/1.1 404 Not Found
{
  "status": false,
  "message": "Item update failed"
}

Leads

Leads – Add New Lead

POSTyourdomain.com/api/leads

Header

FieldTypeDescription
authtokenStringAuthentication token, generated from admin area

Parameter

FieldTypeDescription
sourceStringMandatory Lead source.
statusStringMandatory Lead Status.
nameStringMandatory Lead Name.
assignedStringMandatory Lead assigned.
client_id (optional)StringOptional Lead From Customer.
tags (optional)StringOptional Lead tags.
contact (optional)StringOptional Lead contact.
title (optional)StringOptional Position.
email (optional)StringOptional Lead Email Address.
website (optional)StringOptional Lead Website.
phonenumber (optional)StringOptional Lead Phone.
company (optional)StringOptional Lead company.
address (optional)StringOptional Lead address.
city (optional)StringOptional Lead City.
zip (optional)StringOptional Zip code.
state (optional)StringOptional Lead state.
country (optional)StringOptional Lead Country.
default_language (optional)StringOptional Lead Default Language.
description (optional)StringOptional Lead description.
custom_contact_date (optional)StringOptional Lead From Customer.
contacted_today (optional)StringOptional Lead Contacted Today.
is_public (optional)StringOptional Lead google sheet id.

Success 200

FieldTypeDescription
statusBooleanRequest status.
messageStringLead add successful.

Error 4xx

NameTypeDescription
statusBooleanRequest status.
messageStringadd fail.
HTTP/1.1 200 OK
{
  "status": true,
  "message": "Lead add successful."
}
HTTP/1.1 404 Not Found
{
  "status": false,
  "message": "Lead add fail."
}

Leads – Delete a Lead

DELETEyourdomain.com/api/delete/leads/:id

Header

FieldTypeDescription
authtokenStringAuthentication token, generated from admin area

Parameter

FieldTypeDescription
idNumberlead unique ID.

Success 200

FieldTypeDescription
statusStringRequest status.
messageStringLead Delete Successful.

Error 4xx

NameTypeDescription
statusBooleanRequest status.
messageStringLead Delete Fail.
HTTP/1.1 200 OK
{
  "status": true,
  "message": "Lead Delete Successful."
}
HTTP/1.1 404 Not Found
{
  "status": false,
  "message": "Lead Delete Fail."
}

Leads – Request Lead information

GETyourdomain.com/api/leads/:id

Header

FieldTypeDescription
authtokenStringAuthentication token, generated from admin area

Parameter

FieldTypeDescription
idNumberLead unique ID.

Success 200

FieldTypeDescription
LeadObjectinformation.

Error 4xx

NameTypeDescription
statusBooleanRequest status.
messageStringNo data were found.
HTTP/1.1 200 OK
{
    "id": "17",
    "hash": "c6e938f8b7a40b1bcfd98dc04f6eeee0-60d9c039da373a685fc0f74d4bfae631",
    "name": "Lead name",
    "contact": "",
    "title": "",
    "company": "Themesic Interactive",
    "description": "",
    "country": "243",
    "zip": null,
    "city": "London",
    "zip": "WC13KJ",
    "state": "London",
    "address": "1a The Alexander Suite Silk Point",
    "assigned": "5",
    "dateadded": "2019-07-18 08:59:28",
    "from_form_id": "0",
    "status": "0",
    "source": "4",
    ...
}
HTTP/1.1 404 Not Found
{
  "status": false,
  "message": "No data were found"
}

Leads – Request all Leads

GETyourdomain.com/api/leads/

Header

FieldTypeDescription
authtokenStringAuthentication token, generated from admin area

Success 200

FieldTypeDescription
LeadObjectinformation.

Error 4xx

NameTypeDescription
statusBooleanRequest status.
messageStringNo data were found.
HTTP/1.1 200 OK
{
    "id": "17",
    "hash": "c6e938f8b7a40b1bcfd98dc04f6eeee0-60d9c039da373a685fc0f74d4bfae631",
    "name": "Lead name",
    "contact": "",
    "title": "",
    "company": "Themesic Interactive",
    "description": "",
    "country": "243",
    "zip": null,
    "city": "London",
    "zip": "WC13KJ",
    "state": "London",
    "address": "1a The Alexander Suite Silk Point",
    "assigned": "5",
    "dateadded": "2019-07-18 08:59:28",
    "from_form_id": "0",
    "status": "0",
    "source": "4",
    ...
}
HTTP/1.1 404 Not Found
{
  "status": false,
  "message": "No data were found"
}

Leads – Search Lead Information

GETyourdomain.com/api/leads/search/:keysearch

Header

FieldTypeDescription
authtokenStringAuthentication token, generated from admin area

Parameter

FieldTypeDescription
keysearchStringSearch Keywords.

Success 200

FieldTypeDescription
LeadObjectinformation.

Error 4xx

NameTypeDescription
statusBooleanRequest status.
messageStringNo data were found.
HTTP/1.1 200 OK
{
    "id": "17",
    "hash": "c6e938f8b7a40b1bcfd98dc04f6eeee0-60d9c039da373a685fc0f74d4bfae631",
    "name": "Lead name",
    "contact": "",
    "title": "",
    "company": "Themesic Interactive",
    "description": "",
    "country": "243",
    "zip": null,
    "city": "London",
    "zip": "WC13KJ",
    "state": "London",
    "address": "1a The Alexander Suite Silk Point",
    "assigned": "5",
    "dateadded": "2019-07-18 08:59:28",
    "from_form_id": "0",
    "status": "0",
    "source": "4",
    ...
}
HTTP/1.1 404 Not Found
{
  "status": false,
  "message": "No data were found"
}

Leads – Update a lead

PUTyourdomain.com/api/leads/:id

Header

FieldTypeDescription
authtokenStringAuthentication token, generated from admin area

Parameter

FieldTypeDescription
sourceStringMandatory Lead source.
statusStringMandatory Lead Status.
nameStringMandatory Lead Name.
assignedStringMandatory Lead assigned.
client_id (optional)StringOptional Lead From Customer.
tags (optional)StringOptional Lead tags.
contact (optional)StringOptional Lead contact.
title (optional)StringOptional Position.
email (optional)StringOptional Lead Email Address.
website (optional)StringOptional Lead Website.
phonenumber (optional)StringOptional Lead Phone.
company (optional)StringOptional Lead company.
address (optional)StringOptional Lead address.
city (optional)StringOptional Lead City.
zip (optional)StringOptional Zip Code.
state (optional)StringOptional Lead state.
country (optional)StringOptional Lead Country.
default_language (optional)StringOptional Lead Default Language.
description (optional)StringOptional Lead description.
lastcontact (optional)StringOptional Lead Last Contact.
is_public (optional)StringOptional Lead google sheet id.

Success 200

FieldTypeDescription
statusBooleanRequest status.
messageStringLead Update Successful.

Error 4xx

NameTypeDescription
statusBooleanRequest status.
messageStringLead Update Fail.
HTTP/1.1 200 OK
{
  "status": true,
  "message": "Lead Update Successful."
}
HTTP/1.1 404 Not Found
{
  "status": false,
  "message": "Lead Update Fail."
}

Milestones

Milestones – Add New Milestone

POSTyourdomain.com/api/milestones

Header

FieldTypeDescription
authtokenStringAuthentication token, generated from admin area

Parameter

FieldTypeDescription
project_idStringMandatory project id.
nameStringMandatory Milestone Name.
due_dateDateMandatory Milestone Due date.
description (optional)StringOptional Milestone Description.
description_visible_to_customer (optional)StringShow description to customer.
milestone_order (optional)StringOptional Milestone Order.

Success 200

FieldTypeDescription
statusStringRequest status.
messageStringMilestone add successful.

Error 4xx

NameTypeDescription
statusStringRequest status.
messageStringMilestone add fail.
HTTP/1.1 200 OK
{
  "status": true,
  "message": "Milestone add successful."
}
HTTP/1.1 404 Not Found
{
  "status": false,
  "message": "Milestone add fail."
}

Milestones – Delete a Milestone

DELETEyourdomain.com/api/delete/milestones/:id

Header

FieldTypeDescription
authtokenStringAuthentication token, generated from admin area

Parameter

FieldTypeDescription
idNumberMilestone unique ID.

Success 200

FieldTypeDescription
statusStringRequest status.
messageStringMilestone Delete Successful.

Error 4xx

NameTypeDescription
statusStringRequest status.
messageStringMilestone Delete Fail.
HTTP/1.1 200 OK
{
  "status": true,
  "message": "Milestone Delete Successful."
}
HTTP/1.1 404 Not Found
{
  "status": false,
  "message": "Milestone Delete Fail."
}

Milestones – Request Milestones information

GETyourdomain.com/api/milestones/:id

Header

FieldTypeDescription
authtokenStringAuthentication token, generated from admin area

Parameter

FieldTypeDescription
idNumberMilestones unique ID.

Success 200

FieldTypeDescription
MilestonesObjectinformation.

Error 4xx

NameTypeDescription
statusBooleanRequest status.
messageStringNo data were found.
  HTTP/1.1 200 OK
{
    "id": "5",
    "name": "MIlestone A",
    "description": "",
    "description_visible_to_customer": "0",
    "due_date": "2019-09-30",
    "project_id": "2",
    "color": null,
    "milestone_order": "1",
    "datecreated": "2019-07-19",
    "total_tasks": "0",
    "total_finished_tasks": "0"
}
HTTP/1.1 404 Not Found
{
  "status": false,
  "message": "No data were found"
}

Milestones – Search Milestones Information

GETyourdomain.com/api/milestones/search/:keysearch

Header

FieldTypeDescription
authtokenStringAuthentication token, generated from admin area

Parameter

FieldTypeDescription
keysearchStringSearch Keywords.

Success 200

FieldTypeDescription
MilestonesObjectinformation.

Error 4xx

NameTypeDescription
statusBooleanRequest status.
messageStringNo data were found.
HTTP/1.1 200 OK
    {
      "id": "5",
      "name": "MIlestone A",
      "description": "",
      "description_visible_to_customer": "0",
      "due_date": "2019-09-30",
      "project_id": "2",
      "color": null,
      "milestone_order": "1",
      "datecreated": "2019-07-19",
      "total_tasks": "0",
      "total_finished_tasks": "0"
  }
HTTP/1.1 404 Not Found
{
  "status": false,
  "message": "No data were found"
}

Milestones – Update a Milestone

PUTyourdomain.com/api/milestones/:id

Header

FieldTypeDescription
authtokenStringAuthentication token, generated from admin area

Parameter

FieldTypeDescription
project_idStringMandatory project id.
nameStringMandatory Milestone Name.
due_dateDateMandatory Milestone Due date.
description (optional)StringOptional Milestone Description.
description_visible_to_customer (optional)StringShow description to customer.
milestone_order (optional)StringOptional Milestone Order.

Success 200

FieldTypeDescription
statusStringRequest status.
messageStringMilestone Update Successful.

Error 4xx

NameTypeDescription
statusStringRequest status.
messageStringMilestone Update Fail.
HTTP/1.1 200 OK
{
  "status": true,
  "message": "Milestone Update Successful."
}
HTTP/1.1 404 Not Found
{
  "status": false,
  "message": "Milestone Update Fail."
}

Payment Modes

Payment_Modes – Request Payment Modes

GETyourdomain.com/api/common/payment_mode

Header

FieldTypeDescription
authtokenStringAuthentication token, generated from admin area

Success 200

FieldTypeDescription
PaymentArrayModes.

Error 4xx

NameTypeDescription
statusBooleanRequest status.
messageStringNo data were found.
 HTTP/1.1 200 OK
[
    {
        "id": "1",
        "name": "Bank",
        "description": null,
        "show_on_pdf": "0",
        "invoices_only": "0",
        "expenses_only": "0",
        "selected_by_default": "1",
        "active": "1"
    }
]
HTTP/1.1 404 Not Found
{
  "status": false,
  "message": "No data were found"
}

Payments

Payments – Add New Payment

POSTyourdomain.com/api/payments

Header

FieldTypeDescription
authtokenStringAuthentication token, generated from admin area

Parameter

FieldTypeDescription
invoiceidStringMandatory Invoice ID associated with the payment.
amountStringMandatory Payment amount.
paymentmodeStringMandatory Payment mode (e.g., cash, credit card, etc.).
paymentmethod (optional)StringOptional Payment method details.
note (optional)StringOptional Additional payment note.
transactionid (optional)StringOptional Transaction ID.
custom_fields (optional)StringOptional Custom fields data.

Success 200

FieldTypeDescription
paymentmodeBooleanStatus of the request.
messageStringPayment add successful.

Error 4xx

NameTypeDescription
paymentmodeBooleanStatus of the request.
messageStringPayment add fail.
HTTP/1.1 200 OK
{
  "paymentmode": true,
  "message": "Payment add successful."
}
HTTP/1.1 404 Not Found
{
  "paymentmode": false,
  "message": "Payment add fail."
}

Payments – List all Payments

GETyourdomain.com/api/payments/:id

Header

FieldTypeDescription
authtokenStringAuthentication token, generated from admin area

Parameter

FieldTypeDescription
payment_idNumberOptional payment unique ID
Note : if you don’t pass Payment id then it will list all payments records

Success 200

FieldTypeDescription
PaymentsArrayList all Payment Records.

Error 4xx

NameTypeDescription
paymentmodeBooleanRequest paymentmode.
messageStringNo data were found.
  HTTP/1.1 200 OK
[
    {
        "id": "3",
        "invoiceid": "7",
        "amount": "1000.00",
        "paymentmode": "3",
        "paymentmethod": "",
        "date": "2020-06-08",
        "daterecorded": "2020-06-08 20:29:54",
        "note": "",
        "transactionid": "000355795931",
        "invoiceid": "UPI",
        "description": "",
        "show_on_pdf": "0",
        "invoices_only": "0",
        "expenses_only": "0",
        "selected_by_default": "0",
        "active": "1",
        "paymentid": "1"
    },
    {
        "id": "4",
        "invoiceid": "12",
        "amount": "-3.00",
        "paymentmode": "4",
        "paymentmethod": "",
        "date": "2020-07-04",
        "daterecorded": "2020-07-04 15:32:59",
        "note": "",
        "transactionid": "P228210122733439",
        "invoiceid": "Stripe",
        "description": "",
        "show_on_pdf": "0",
        "invoices_only": "0",
        "expenses_only": "0",
        "selected_by_default": "0",
        "active": "1",
        "paymentid": "2"
    },
    {
        "id": "1",
        "invoiceid": "14",
        "amount": "8.00",
        "paymentmode": "1",
        "paymentmethod": "",
        "date": "2020-07-04",
        "daterecorded": "2020-07-04 15:47:30",
        "note": "",
        "transactionid": "000360166374",
        "invoiceid": "Bank",
        "description": null,
        "show_on_pdf": "0",
        "invoices_only": "0",
        "expenses_only": "0",
        "selected_by_default": "1",
        "active": "1",
        "paymentid": "3"
    },
    {
        "id": "2",
        "invoiceid": "13",
        "amount": "3.00",
        "paymentmode": "2",
        "paymentmethod": "Credit card",
        "date": "2020-07-04",
        "daterecorded": "2020-07-04 15:49:56",
        "note": "",
        "transactionid": "0124875873",
        "invoiceid": "paypal",
        "description": "",
        "show_on_pdf": "0",
        "invoices_only": "0",
        "expenses_only": "0",
        "selected_by_default": "0",
        "active": "1",
        "paymentid": "4"
    }
]
HTTP/1.1 404 Not Found
{
  "paymentmode": false,
  "message": "No data were found"
}

Payments – Search Payments Information

GETyourdomain.com/api/payments/search/:keysearch

Header

FieldTypeDescription
authtokenStringAuthentication token, generated from admin area

Parameter

FieldTypeDescription
keysearchStringSearch Keywords

Success 200

FieldTypeDescription
PaymentsArrayPayments information

Error 4xx

NameTypeDescription
paymentmodeBooleanRequest paymentmode
messageStringNo data were found
HTTP/1.1 200 OK
[
    {
        "id": "3",
        "invoiceid": "14",
        "amount": "8.00",
        "paymentmode": "2",
        "paymentmethod": "",
        "date": "2020-07-04",
        "daterecorded": "2020-07-04 15:47:30",
        "note": "",
        "transactionid": "",
        ...
    }
]
HTTP/1.1 404 Not Found
{
  "paymentmode": false,
  "message": "No data were found"
}

Projects

Projects – Add New Project

POSTyourdomain.com/api/projects

Header

FieldTypeDescription
authtokenStringAuthentication token, generated from admin area

Parameter

FieldTypeDescription
nameStringMandatory Project Name.
rel_typestringMandatory Project Related.Allowed values: "lead""customer""internal"
clientidNumberMandatory Related ID.
billing_typeNumberMandatory Billing Type.
start_dateDateMandatory Project Start Date.
statusNumberMandatory Project Status.
progress_from_tasks (optional)StringOptional on or off progress from tasks.
project_cost (optional)StringOptional Project Cost.
progress (optional)StringOptional project progress.
project_rate_per_hour (optional)StringOptional project rate per hour.
estimated_hours (optional)StringOptional Project estimated hours.
project_members (optional)Number[]Optional Project members.
deadline (optional)DateOptional Project deadline.
tags (optional)StringOptional Project tags.
description (optional)StringOptional Project description.

Success 200

FieldTypeDescription
statusBooleanRequest status.
messageStringProject add successful.

Error 4xx

NameTypeDescription
statusBooleanRequest status.
messageStringProject add fail.
HTTP/1.1 200 OK
{
  "status": true,
  "message": "Project add successful."
}
HTTP/1.1 404 Not Found
{
  "status": false,
  "message": "Project add fail."
}

Projects – Delete a Project

DELETEyourdomain.com/api/delete/projects/:id

Header

FieldTypeDescription
authtokenStringAuthentication token, generated from admin area

Parameter

FieldTypeDescription
idNumberproject unique ID.

Success 200

FieldTypeDescription
statusBooleanRequest status.
messageStringProject Delete successful.

Error 4xx

NameTypeDescription
statusBooleanRequest status.
messageStringProject Delete Fail.
HTTP/1.1 200 OK
{
  "status": true,
  "message": "Project Delete Successful."
}
HTTP/1.1 404 Not Found
{
  "status": false,
  "message": "Project Delete Fail."
}

Projects – Request project information

GETyourdomain.com/api/projects/:id

Header

FieldTypeDescription
authtokenStringAuthentication token, generated from admin area

Parameter

FieldTypeDescription
idNumberproject unique ID.

Success 200

FieldTypeDescription
ProjectObjectinformation.

Error 4xx

NameTypeDescription
statusBooleanRequest status.
messageStringNo data were found.
HTTP/1.1 200 OK
{
     "id": "28",
     "name": "Test1",
     "description": null,
     "status": "1",
     "clientid": "11",
     "billing_type": "3",
     "start_date": "2019-04-19",
     "deadline": "2019-08-30",
     "project_created": "2019-07-16",
     "date_finished": null,
     "progress": "0",
     "progress_from_tasks": "1",
     "project_cost": "0.00",
     "project_rate_per_hour": "0.00",
     "estimated_hours": "0.00",
     "addedfrom": "5",
     "rel_type": "lead",
     "potential_revenue": "0.00",
     "potential_margin": "0.00",
     "external": "E",
    ...
}
HTTP/1.1 404 Not Found
{
  "status": false,
  "message": "No data were found"
}

Projects – Search Project Information

GETyourdomain.com/api/projects/search/:keysearch

Header

FieldTypeDescription
authtokenStringAuthentication token, generated from admin area

Parameter

FieldTypeDescription
keysearchStringSearch keywords.

Success 200

FieldTypeDescription
ProjectObjectinformation.

Error 4xx

NameTypeDescription
statusBooleanRequest status.
messageStringNo data were found.
HTTP/1.1 200 OK
{
     "id": "28",
     "name": "Test1",
     "description": null,
     "status": "1",
     "clientid": "11",
     "billing_type": "3",
     "start_date": "2019-04-19",
     "deadline": "2019-08-30",
     "project_created": "2019-07-16",
     "date_finished": null,
     "progress": "0",
     "progress_from_tasks": "1",
     "project_cost": "0.00",
     "project_rate_per_hour": "0.00",
     "estimated_hours": "0.00",
     "addedfrom": "5",
     "rel_type": "lead",
     "potential_revenue": "0.00",
     "potential_margin": "0.00",
     "external": "E",
    ...
}
HTTP/1.1 404 Not Found
{
  "status": false,
  "message": "No data were found"
}

Projects – Update a project

PUTyourdomain.com/api/projects/:id

Header

FieldTypeDescription
authtokenStringAuthentication token, generated from admin area

Parameter

FieldTypeDescription
nameStringMandatory Project Name.
rel_typestringMandatory Project Related.Allowed values: "lead""customer""internal"
clientidNumberMandatory Related ID.
billing_typeNumberMandatory Billing Type.
start_dateDateMandatory Project Start Date.
statusNumberMandatory Project Status.
progress_from_tasks (optional)StringOptional on or off progress from tasks.
project_cost (optional)StringOptional Project Cost.
progress (optional)StringOptional project progress.
project_rate_per_hour (optional)StringOptional project rate per hour.
estimated_hours (optional)StringOptional Project estimated hours.
project_members (optional)Number[]Optional Project members.
deadline (optional)DateOptional Project deadline.
tags (optional)StringOptional Project tags.
description (optional)StringOptional Project description.

Success 200

FieldTypeDescription
statusBooleanRequest status.
messageStringProject Update Successful.

Error 4xx

NameTypeDescription
statusBooleanRequest status.
messageStringProject Update Fail.
HTTP/1.1 200 OK
{
  "status": true,
  "message": "Project Update Successful."
}
HTTP/1.1 404 Not Found
{
  "status": false,
  "message": "Project Update Fail."
}

Proposals

Proposals – Add New Proposals

POSTyourdomain.com/api/proposals

Header

FieldTypeDescription
authtokenStringAuthentication token, generated from admin area

Parameter

FieldTypeDescription
subjectStringMandatory. Proposal Subject Name.
RelatedstringMandatory. Proposal Related.Allowed values: "lead""customer"
rel_idNumberMandatory. Related ID.
proposal_tostringMandatory. Lead / Customer name.
dateDateMandatory. Proposal Start Date.
open_tillDateOptional. Proposal Open Till Date.
currencystringMandatory. currency id.
discount_typestringOptional. Proposal Open Till Date.
statusstringOptional. status id.
AssignedstringOptional. Assignee id.
EmailstringMandatory. Email id.
newitemsArrayMandatory. New Items to be added.

Success 200

FieldTypeDescription
statusBooleanRequest status.
messageStringProposal add successful.

Error 4xx

NameTypeDescription
statusBooleanRequest status.
messageStringProposal add fail.
HTTP/1.1 200 OK
{
  "status": true,
  "message": "Proposal add successful."
}
HTTP/1.1 404 Not Found
{
  "status": false,
  "message": "Proposal add fail."
}

Proposals – Delete Proposal

DELETEyourdomain.com/api/proposals/:id

Header

FieldTypeDescription
authtokenStringAuthentication token, generated from admin area

Parameter

FieldTypeDescription
idNumberProposal unique ID.

Success 200

FieldTypeDescription
statusBooleanRequest status.
messageStringProposals Deleted Successfully

Error 4xx

NameTypeDescription
statusBooleanRequest status.
messageStringProposals Delete Fail
HTTP/1.1 200 OK
{
  "status": true,
  "message": "Proposals Deleted Successfully"
}
HTTP/1.1 404 Not Found
{
  "status": false,
  "message": "Proposal Delete Fail"
}

Proposals – Request Proposal information

GETyourdomain.com/api/proposals

Header

FieldTypeDescription
authtokenStringAuthentication token, generated from admin area

Parameter

FieldTypeDescription
idNumberProposal unique ID

Success 200

FieldTypeDescription
ProposalObjectinformation.

Error 4xx

NameTypeDescription
statusBooleanRequest status.
messageStringNo data were found.
  HTTP/1.1 200 OK
  {
	    "id": "1",
	    "subject": "Test Proposal",
	    "content": "{proposal_items}",
	    "addedfrom": "1",
	    "datecreated": "2021-08-01 13:38:08",
	    "total": "10.00",
	    "subtotal": "10.00",
	    "total_tax": "0.00",
	    "adjustment": "0.00",
	    "discount_percent": "0.00",
	    "discount_total": "0.00",
	    "discount_type": "",
	    "show_quantity_as": "1",
	    "currency": "1",
	    "open_till": "2021-08-08",
	    "date": "2021-08-01",
	    "rel_id": "1",
	    "rel_type": "customer",
	    "assigned": "0",
	    "hash": "9fc38e5ad2f8256b1b8430ee41069f75",
	    "proposal_to": "test",
	    "country": "102",
	    "zip": "30000202",
	    "state": "Test",
	    "city": "Test",
	    "address": "Test",
	    "email": "test@gmail.com",
	    "phone": "01324568903",
	    "allow_comments": "1",
	    "status": "6",
	    "estimate_id": null,
	    "invoice_id": null,
	    "date_converted": null,
	    "pipeline_order": "0",
	    "is_expiry_notified": "0",
	    "acceptance_firstname": null,
	    "acceptance_lastname": null,
	    "acceptance_email": null,
	    "acceptance_date": null,
	    "acceptance_ip": null,
	    "signature": null,
	    "short_link": null,
	    "symbol": "$",
	    "name": "USD",
	    "decimal_separator": ".",
	    "thousand_separator": ",",
	    "placement": "before",
	    "isdefault": "1",
	    "currencyid": "1",
	    "currency_name": "USD",
	    "attachments": [],
	    "items": [
	        {
	            "id": "4",
	            "rel_id": "1",
	            "rel_type": "proposal",
	            "description": "item 1",
	            "long_description": "item 1 description",
	            "qty": "1.00",
	            "rate": "10.00",
	            "unit": "1",
	            "item_order": "1"
	        }
	    ],
	    "visible_attachments_to_customer_found": false,
	    "customfields": [
	        {
	            "label": "Custom Field",
	            "value": "Custom Field value"
	        }
	    ]
	}
HTTP/1.1 404 Not Found
{
  "status": false,
  "message": "No data were found"
}

Proposals – Search proposals information

GETyourdomain.com/api/proposals/search/:keysearch

Header

FieldTypeDescription
authtokenStringAuthentication token, generated from admin area

Parameter

FieldTypeDescription
keysearchStringSearch Keywords.

Success 200

FieldTypeDescription
ProposalsObjectInformation.

Error 4xx

NameTypeDescription
statusBooleanRequest status.
messageStringNo data were found.
 HTTP/1.1 200 OK
   {
 "id": "2",
 "subject": "Test 2",
 "content": "{proposal_items}",
 "addedfrom": "1",
"datecreated": "2021-08-01 13:43:49",
 "total": "10.00",
 "subtotal": "10.00",
 "total_tax": "0.00",
 "adjustment": "0.00",
 "discount_percent": "0.00",
 "discount_total": "0.00",
 "discount_type": "",
 "show_quantity_as": "1",
 "currency": "1",
 "open_till": "2021-08-08",
 "date": "2021-08-01",
 "rel_id": "1",
 "rel_type": "customer",
 "assigned": "0",
 "hash": "6fe6cd0bc66dff03663154660acc1a93",
 "proposal_to": "test",
 "country": "102",
 "zip": "300000",
 "state": "test",
 "city": "test",
 "address": "test",
 "email": "test@gmail.com",
 "phone": "01324568903",
 "allow_comments": "1",
 "status": "6",
 "estimate_id": null,
 "invoice_id": null,
 "date_converted": null,
 "pipeline_order": "0",
 "is_expiry_notified": "0",
 "acceptance_firstname": null,
 "acceptance_lastname": null,
 "acceptance_email": null,
 "acceptance_date": null,
 "acceptance_ip": null,
 "signature": null,
 "short_link": null,
 "symbol": "$",
 "name": "USD",
 "decimal_separator": ".",
 "thousand_separator": ",",
 "placement": "before",
 "isdefault": "1",
 "customfields": [
     {
         "label": "Custom Field",
	        "value": "Custom Field value"
     }
  ]
}
HTTP/1.1 404 Not Found
{
  "status": false,
  "message": "No Data Were Found"
}

Proposals – Update a proposal

PUTyourdomain.com/api/proposal/:id

Header

FieldTypeDescription
authtokenStringAuthentication token, generated from admin area

Parameter

FieldTypeDescription
subjectStringMandatory. Proposal Subject Name.
  stringProposal Related.Allowed values: "lead""customer"
rel_idNumberMandatory. Related ID.
proposal_tostringMandatory. Lead / Customer name.
dateDateMandatory. Proposal Start Date.
open_tillDateOptional. Proposal Open Till Date.
currencystringMandatory. currency id.
discount_typestringOptional. Proposal Open Till Date.
statusstringOptional. status id.
AssignedstringOptional. Assignee id.
EmailstringMandatory. Email id.
newitemsArrayMandatory. New Items to be added.
itemsArrayOptional. Existing items with Id
removed_itemsArrayOptional. Items to be removed
HTTP/1.1 200 OK
{
  "status": false,
  "message": "Proposal Updated Successfully"
}
HTTP/1.1 404 Not Found
{
  "status": false,
  "message": "Proposal Update Fail"
}

Staffs

Staffs – Add New Staff

POSTyourdomain.com/api/staffs

Header

FieldTypeDescription
authtokenStringAuthentication token, generated from admin area

Parameter

FieldTypeDescription
firstnameStringMandatory Staff Name.
emailStringMandatory Staff Related.
passwordStringMandatory Staff password.
hourly_rate (optional)NumberOptional hourly rate.
phonenumber (optional)StringOptional Staff phonenumber.
facebook (optional)StringOptional Staff facebook.
linkedin (optional)StringOptional Staff linkedin.
skype (optional)StringOptional Staff skype.
default_language (optional)StringOptional Staff default language.
email_signature (optional)StringOptional Staff email signature.
direction (optional)StringOptional Staff direction.
send_welcome_email (optional)StringOptional Staff send welcome email.
departments (optional)Number[]Optional Staff departments.

Success 200

FieldTypeDescription
statusStringRequest status.
messageStringStaff add successful.

Error 4xx

NameTypeDescription
statusStringRequest status.
messageStringStaff add fail.
HTTP/1.1 200 OK
{
  "status": true,
  "message": "Staff add successful."
}
HTTP/1.1 404 Not Found
{
  "status": false,
  "message": "Staff add fail."
}

Staffs – Delete a Staff

DELETEyourdomain.com/api/delete/staffs/:id

Header

FieldTypeDescription
authtokenStringAuthentication token, generated from admin area

Parameter

FieldTypeDescription
idNumberStaff unique ID.

Success 200

FieldTypeDescription
statusStringRequest status.
messageStringStaff registration successful.

Error 4xx

NameTypeDescription
statusStringRequest status.
messageStringNot register your accout.
HTTP/1.1 200 OK
{
  "status": true,
  "message": "Staff Delete."
}
HTTP/1.1 404 Not Found
{
  "status": false,
  "message": "Staff Not Delete."
}

Staffs – Request Staff information

GETyourdomain.com/api/staffs/:id

Header

FieldTypeDescription
authtokenStringAuthentication token, generated from admin area

Parameter

FieldTypeDescription
idNumberStaff unique ID.

Success 200

FieldTypeDescription
StaffObjectinformation.

Error 4xx

NameDescription
StaffNotFoundThe id of the Staff was not found.
HTTP/1.1 200 OK
{
     "staffid": "8",
     "email": "data1.gsts@gmail.com",
     "firstname": "Đào Quang Dân",
     "lastname": "",
     "facebook": "",
     "linkedin": "",
     "phonenumber": "",
     "skype": "",
     "password": "$2a$08$ySLokLAM.AqmW9ZjY2YREO0CIrd5K4Td\/Bpfp8d9QJamWNUfreQuK",
     "datecreated": "2019-02-25 09:11:31",
     "profile_image": "8.png",
    ...
}
HTTP/1.1 404 Not Found
{
  "status": false,
  "message": "No data were found"
}

Staffs – Search Staff Information

GETyourdomain.com/api/staffs/search/:keysearch

Header

FieldTypeDescription
authtokenStringAuthentication token, generated from admin area

Parameter

FieldTypeDescription
keysearchStringSearch keywords.

Success 200

FieldTypeDescription
StaffObjectinformation.

Error 4xx

NameDescription
StaffNotFoundThe id of the Staff was not found.
HTTP/1.1 200 OK
{
     "staffid": "8",
     "email": "data1.gsts@gmail.com",
     "firstname": "Đào Quang Dân",
     "lastname": "",
     "facebook": "",
     "linkedin": "",
     "phonenumber": "",
     "skype": "",
     "password": "$2a$08$ySLokLAM.AqmW9ZjY2YREO0CIrd5K4Td\/Bpfp8d9QJamWNUfreQuK",
     "datecreated": "2019-02-25 09:11:31",
     "profile_image": "8.png",
    ...
}
HTTP/1.1 404 Not Found
{
  "status": false,
  "message": "No data were found"
}

Staffs – Update a Staff

PUTyourdomain.com/api/staffs/:id

Header

FieldTypeDescription
authtokenStringAuthentication token, generated from admin area

Parameter

FieldTypeDescription
firstnameStringMandatory Staff Name.
emailStringMandatory Staff Related.
passwordStringMandatory Staff password.
hourly_rate (optional)NumberOptional hourly rate.
phonenumber (optional)StringOptional Staff phonenumber.
facebook (optional)StringOptional Staff facebook.
linkedin (optional)StringOptional Staff linkedin.
skype (optional)StringOptional Staff skype.
default_language (optional)StringOptional Staff default language.
email_signature (optional)StringOptional Staff email signature.
direction (optional)StringOptional Staff direction.
departments (optional)Number[]Optional Staff departments.

Success 200

FieldTypeDescription
statusStringRequest status.
messageStringStaff Update Successful.

Error 4xx

NameTypeDescription
statusStringRequest status.
messageStringStaff Update Fail.
HTTP/1.1 200 OK
{
  "status": true,
  "message": "Staff Update Successful."
}
HTTP/1.1 404 Not Found
{
  "status": false,
  "message": "Staff Update Fail."
}

Subscriptions

Subscriptions – Add New Subscription

POSTyourdomain.com/api/subscriptions/

Header

FieldTypeDescription
authtokenStringAuthentication token, generated from admin area

Parameter

FieldTypeDescription
nameStringNew subscription name.
descriptionTextDetailed description of the subscription.
description_in_itemTinyIntIndicates if the description is included in the item (1 or 0).
clientidIntClient ID.
dateDateSubscription start date (YYYY-MM-DD).
termsTextSubscription terms.
currencyIntCurrency ID.
tax_idIntTax ID.
stripe_tax_id_2VarcharStripe tax ID.
stripe_plan_idTextStripe plan ID.
stripe_subscription_idTextStripe Subscription ID.
tax_id_2IntSecond tax ID.
next_billing_cycleBigIntNext billing cycle timestamp.
ends_atBigIntSubscription end timestamp.
statusVarcharSubscription status (e.g., active).
quantityIntSubscription quantity.
project_idIntAssociated project ID.
hashVarcharUnique hash identifier.
createdDateTimeCreation timestamp (YYYY-MM-DD HH:MM:SS).
created_fromIntID of the creator.
date_subscribedDateTimeSubscription date (YYYY-MM-DD HH:MM:SS).
in_test_environmentIntIndicates if the subscription is in a test environment (1 or 0).
last_sent_atDateTimeLast sent timestamp (YYYY-MM-DD HH:MM:SS).

Success 200

FieldTypeDescription
statusBooleanRequest status.
messageStringSuccess message.

Error 4xx

NameDescription
DataNotAddedData could not be added.
HTTP/1.1 200 OK
{
    "status": true,
    "message": "Data Added Successfully"
}
HTTP/1.1 400 Bad Request
{
    "status": false,
    "error": "Data not Added"
}

Subscriptions – Delete a Subscription

DELETEyourdomain.com/api/subscriptions/:id

Header

FieldTypeDescription
authtokenStringAuthentication token, generated from admin area

Parameter

FieldTypeDescription
ididID for data Deletion.

Error 4xx

NameDescription
  
HTTP/1.1 200 OK
 {
     "status": true,
     "message": "Delete Successful."
 }
   HTTP/1.1 404 Not Found
{
    "status": false,
    "message": "Delete Fail."
}

Subscriptions – Request Subscription Information

GETyourdomain.com/api/subscriptions/:id

Header

FieldTypeDescription
authtokenStringAuthentication token, generated from admin area

Parameter

FieldTypeDescription
ididData id ID.

Success 200

FieldTypeDescription
DataObjectInformation

Error 4xx

NameDescription
DataNotFoundThe id of the data was not found.
HTTP/1.1 200 OK
[
    {
     'name' => varchar 'New  subscription'
     'description' => text 'This is a detailed description of subscription'
     'description_in_item' => tinyint '1'
     'clientid' => int '123'
     'date' => date '2024-01-31'
     'terms' => text 'subscription payment is due'
     'currency ' => int '4'
     'tax_id ' => int '456'
     'stripe_tax_id_2' => varchar 'tax-789' 
     'stripe_plan_id' => text 'subscription_ABC'
     'stripe_subscription_id' => text 'subscription_ABC'
     'tax_id_2': int '12',
     'stripe_subscription_id' => text 'sub_123456789'
     'next_billing_cycle' => bigint '1643808000'
     'ends_at' => bigint '1646486400'
     'status' => varchar 'active'
     'quantity' => int '5'
     'project_id' => int '789'
     'hash' => varchar 'a1b2c3' 
     'created' => datetime '2024-01-31 12:34:56'
     'created_from' => int '1' 
     'date_subscribed' => datetime '2024-01-31 10:00:00'
     'in_test_environment' => int '1' 
     'last_sent_at' => datetime '2024-01-31 14:45:00'
    }
]
HTTP/1.1 404 Not Found
{
    "status": false,
    "message": "No data were found"
}

Subscriptions – Request all Subscriptions

GETyourdomain.com/api/subscriptions/

Header

FieldTypeDescription
authtokenStringAuthentication token, generated from admin area

Success 200

FieldTypeDescription
DataObjectInformation

Error 4xx

NameDescription
DataNotFoundThe id of the data was not found.
HTTP/1.1 200 OK
[
    {
     'name' => varchar 'New  subscription'
     'description' => text 'This is a detailed description of subscription'
     'description_in_item' => tinyint '1'
     'clientid' => int '123'
     'date' => date '2024-01-31'
     'terms' => text 'subscription payment is due'
     'currency ' => int '4'
     'tax_id ' => int '456'
     'stripe_tax_id_2' => varchar 'tax-789' 
     'stripe_plan_id' => text 'subscription_ABC'
     'stripe_subscription_id' => text 'subscription_ABC'
     'tax_id_2': int '12',
     'stripe_subscription_id' => text 'sub_123456789'
     'next_billing_cycle' => bigint '1643808000'
     'ends_at' => bigint '1646486400'
     'status' => varchar 'active'
     'quantity' => int '5'
     'project_id' => int '789'
     'hash' => varchar 'a1b2c3' 
     'created' => datetime '2024-01-31 12:34:56'
     'created_from' => int '1' 
     'date_subscribed' => datetime '2024-01-31 10:00:00'
     'in_test_environment' => int '1' 
     'last_sent_at' => datetime '2024-01-31 14:45:00'
    }
]
HTTP/1.1 404 Not Found
{
    "status": false,
    "message": "No data were found"
}

Subscriptions – Update a Subscription

PUTyourdomain.com/api/subscriptions/:id

Header

FieldTypeDescription
authtokenStringAuthentication token, generated from admin area

Parameter

FieldTypeDescription
ididID for update data.
HTTP/1.1 200 OK
{
  "status": true,
  "message": "Data Update Successful."
}
    HTTP/1.1 404 Not Found
 {
      "status": false,
      "message": "Data Not Acceptable OR Not Provided"
 }

{
   "status": false,
   "message": "Data Update Fail."
}

Tasks

Tasks – Add Checklist Item to Task

POSTyourdomain.com/api/tasks/:id/checklist

Header

FieldTypeDescription
authtokenStringAuthentication token, generated from admin area

Parameter

FieldTypeDescription
idNumberTask unique ID.
descriptionStringMandatory Checklist item description.
assigned (optional)NumberOptional Staff ID to assign this item to.
list_order (optional)NumberOptional Sort order (defaults to highest + 1).

Success 200

FieldTypeDescription
statusBooleanRequest status.
messageStringSuccess message.
checklist_item_idNumberID of created checklist item.

Error 4xx

NameTypeDescription
statusBooleanRequest status.
messageStringError message.
HTTP/1.1 200 OK
{
  "status": true,
  "message": "Checklist item added successfully",
  "checklist_item_id": 15
}
HTTP/1.1 400 Bad Request
{
  "status": false,
  "message": "Description is required"
}

Tasks – Add New Task

POSTyourdomain.com/api/tasks

Header

FieldTypeDescription
authtokenStringAuthentication token, generated from admin area

Parameter

FieldTypeDescription
nameStringMandatory Task Name.
startdateDateMandatory Task Start Date.
is_public (optional)StringOptional Task public.
billable (optional)StringOptional Task billable.
hourly_rate (optional)StringOptional Task hourly rate.
milestone (optional)StringOptional Task milestone.
duedate (optional)DateOptional Task deadline.
priority (optional)StringOptional Task priority.
repeat_every (optional)StringOptional Task repeat every.
repeat_every_custom (optional)NumberOptional Task repeat every custom.
repeat_type_custom (optional)StringOptional Task repeat type custom.
cycles (optional)NumberOptional cycles.
rel_typestringMandatory Task Related.Allowed values: "lead""customer""invoice""project""quotation""contract""annex""ticket""expense""proposal"
rel_idNumberOptional Related ID.
tags (optional)StringOptional Task tags.
description (optional)StringOptional Task description.
assignees (optional)MixedOptional Task assignees. Can be: array of staff IDs, comma-separated string “1,2,3”, or JSON array “[1,2,3]”.

Success 200

FieldTypeDescription
statusStringRequest status.
messageStringTask add successful.

Error 4xx

NameTypeDescription
statusStringRequest status.
messageStringTask add fail.
HTTP/1.1 200 OK
{
  "status": true,
  "message": "Task add successful."
}
HTTP/1.1 404 Not Found
{
  "status": false,
  "message": "Task add fail."
}

Tasks – Delete Checklist Item

DELETEyourdomain.com/api/tasks/:task_id/checklist/:item_id

Header

FieldTypeDescription
authtokenStringAuthentication token, generated from admin area

Parameter

FieldTypeDescription
task_idNumberTask unique ID.
item_idNumberChecklist item ID.

Success 200

FieldTypeDescription
statusBooleanRequest status.
messageStringSuccess message.

Error 4xx

NameTypeDescription
statusBooleanRequest status.
messageStringError message.
HTTP/1.1 200 OK
{
  "status": true,
  "message": "Checklist item deleted successfully"
}

Tasks – Delete a Task

DELETEyourdomain.com/api/delete/tasks/:id

Header

FieldTypeDescription
authtokenStringAuthentication token, generated from admin area

Parameter

FieldTypeDescription
idNumberTask unique ID.

Success 200

FieldTypeDescription
statusStringRequest status.
messageStringTask Delete Successful.

Error 4xx

NameTypeDescription
statusStringRequest status.
messageStringTask Delete Fail.
HTTP/1.1 200 OK
{
  "status": true,
  "message": "Task Delete Successful."
}
HTTP/1.1 404 Not Found
{
  "status": false,
  "message": "Task Delete Fail."
}

Tasks – Get Task Checklist Items

GETyourdomain.com/api/tasks/:id/checklist

Header

FieldTypeDescription
authtokenStringAuthentication token, generated from admin area

Parameter

FieldTypeDescription
idNumberTask unique ID.

Success 200

FieldTypeDescription
checklistObject[]Array of checklist items.
  idNumberChecklist item ID.
  taskidNumberTask ID.
  descriptionStringChecklist item description.
  finishedNumber0=unchecked, 1=checked.
  dateaddedDateTimeDate when item was added.
  addedfromNumberStaff ID who added the item.
  finished_fromNumberStaff ID who checked the item.
  list_orderNumberSort order.
  assignedNumberStaff ID assigned to this item.

Error 4xx

NameTypeDescription
statusBooleanRequest status.
messageStringTask not found or no checklist items.
HTTP/1.1 200 OK
[
  {
    "id": "1",
    "taskid": "10",
    "description": "Review documentation",
    "finished": "0",
    "dateadded": "2025-01-23 10:30:00",
    "addedfrom": "1",
    "finished_from": "0",
    "list_order": "1",
    "assigned": "2"
  }
]
HTTP/1.1 404 Not Found
{
  "status": false,
  "message": "Task not found or no checklist items"
}

Tasks – Request Task information

GETyourdomain.com/api/tasks/:id

Header

FieldTypeDescription
authtokenStringAuthentication token, generated from admin area

Parameter

FieldTypeDescription
idNumberTask unique ID.

Success 200

FieldTypeDescription
TasksObjectinformation.

Error 4xx

NameTypeDescription
statusBooleanRequest status.
messageStringNo data were found.
HTTP/1.1 200 OK
{
    "id": "10",
    "name": "This is a task",
    "description": "",
    "priority": "2",
    "dateadded": "2019-02-25 12:26:37",
    "startdate": "2019-01-02 00:00:00",
    "duedate": "2019-01-04 00:00:00",
    "datefinished": null,
    "addedfrom": "9",
    "is_added_from_contact": "0",
    "status": "4",
    "recurring_type": null,
    "repeat_every": "0",
    "recurring": "0",
    "is_recurring_from": null,
    ...
}
HTTP/1.1 404 Not Found
{
  "status": false,
  "message": "No data were found"
}

Tasks – Search Tasks Information

GETyourdomain.com/api/tasks/search/:keysearch

Header

FieldTypeDescription
authtokenStringAuthentication token, generated from admin area

Parameter

FieldTypeDescription
keysearchStringSearch Keywords.

Success 200

FieldTypeDescription
TasksObjectinformation.

Error 4xx

NameTypeDescription
statusBooleanRequest status.
messageStringNo data were found.
HTTP/1.1 200 OK
{
    "id": "10",
    "name": "This is a task",
    "description": "",
    "priority": "2",
    "dateadded": "2019-02-25 12:26:37",
    "startdate": "2019-01-02 00:00:00",
    "duedate": "2019-01-04 00:00:00",
    "datefinished": null,
    "addedfrom": "9",
    "is_added_from_contact": "0",
    "status": "4",
    "recurring_type": null,
    "repeat_every": "0",
    "recurring": "0",
    "is_recurring_from": null,
    ...
}
HTTP/1.1 404 Not Found
{
  "status": false,
  "message": "No data were found"
}

Tasks – Update Checklist Item

PUTyourdomain.com/api/tasks/:task_id/checklist/:item_id

Header

FieldTypeDescription
authtokenStringAuthentication token, generated from admin area

Parameter

FieldTypeDescription
task_idNumberTask unique ID.
item_idNumberChecklist item ID.
description (optional)StringOptional Updated description.
finished (optional)NumberOptional 0=unchecked, 1=checked.
assigned (optional)NumberOptional Staff ID to assign.
list_order (optional)NumberOptional Sort order.

Success 200

FieldTypeDescription
statusBooleanRequest status.
messageStringSuccess message.

Error 4xx

NameTypeDescription
statusBooleanRequest status.
messageStringError message.
HTTP/1.1 200 OK
{
  "status": true,
  "message": "Checklist item updated successfully"
}

Tasks – Update a task

PUTyourdomain.com/api/tasks/:id

Header

FieldTypeDescription
authtokenStringAuthentication token, generated from admin area

Parameter

FieldTypeDescription
name (optional)StringOptional Task Name.
startdate (optional)DateOptional Task Start Date.
status (optional)NumberOptional Task status (0-5).
is_public (optional)StringOptional Task public.
billable (optional)StringOptional Task billable.
hourly_rate (optional)StringOptional Task hourly rate.
milestone (optional)StringOptional Task milestone.
duedate (optional)DateOptional Task deadline.
priority (optional)StringOptional Task priority.
repeat_every (optional)StringOptional Task repeat every.
repeat_every_custom (optional)NumberOptional Task repeat every custom.
repeat_type_custom (optional)StringOptional Task repeat type custom.
cycles (optional)NumberOptional cycles.
rel_typestringOptional Task Related.Allowed values: "lead""customer""invoice""project""quotation""contract""annex""ticket""expense""proposal"
rel_idNumberOptional Related ID.
tags (optional)StringOptional Task tags.
description (optional)StringOptional Task description.
assignees (optional)MixedOptional Task assignees. Can be: array of staff IDs, comma-separated string “1,2,3”, or JSON array “[1,2,3]”.

Success 200

FieldTypeDescription
statusStringRequest status.
messageStringTask Update Successful.

Error 4xx

NameTypeDescription
statusStringRequest status.
messageStringTask Update Fail.
HTTP/1.1 200 OK
{
  "status": true,
  "message": "Task Update Successful."
}
HTTP/1.1 404 Not Found
{
  "status": false,
  "message": "Task Update Fail."
}

Taxes

Taxes – Request Taxes

GETyourdomain.com/api/common/tax_data

Header

FieldTypeDescription
authtokenStringAuthentication token, generated from admin area

Success 200

FieldTypeDescription
TaxArrayinformation.

Error 4xx

NameTypeDescription
statusBooleanRequest status.
messageStringNo data were found.
 HTTP/1.1 200 OK
[
    {
        "id": "4",
        "name": "PAYPAL",
        "taxrate": "5.00"
    },
    {
        "id": "1",
        "name": "CGST",
        "taxrate": "9.00"
    },
    {
        "id": "2",
        "name": "SGST",
        "taxrate": "9.00"
    },
    {
        "id": "3",
        "name": "GST",
        "taxrate": "18.00"
    }
]
HTTP/1.1 404 Not Found
{
  "status": false,
  "message": "No data were found"
}

Thirdparty

Thirdparty – Delete Record from Custom Table

Deletes a record from the specified custom table by its ID.

DELETEyourdomain.com/api/thirdparty/customtable/:table_name/:id

Header

FieldTypeDescription
authtokenStringAuthentication token, generated from admin area

Parameter

FieldTypeDescription
table_nameStringName of the custom database table (exact table name as it exists in the database)
idNumberRecord ID

Success 200

FieldTypeDescription
statusBooleanRequest status
messageStringSuccess message

Error 4xx

NameTypeDescription
statusBooleanRequest status
messageStringError message
HTTP/1.1 200 OK
{
  "status": true,
  "message": "Record deleted successfully"
}
HTTP/1.1 404 Not Found
{
  "status": false,
  "message": "Record not found"
}

Thirdparty – Get All Records from Custom Table

Retrieves all records from the specified custom table. The table name should be the exact name as it exists in the database (no prefix will be added).

GETyourdomain.com/api/thirdparty/customtable/:table_name

Header

FieldTypeDescription
authtokenStringAuthentication token, generated from admin area

Parameter

FieldTypeDescription
table_nameStringName of the custom database table (exact table name as it exists in the database)

Success 200

FieldTypeDescription
ArrayArrayof records with all columns and values

Error 4xx

NameTypeDescription
statusBooleanRequest status
messageStringError message
HTTP/1.1 200 OK
[
  {
    "id": "1",
    "shoenumber": "39",
    "winter": "40"
  },
  {
    "id": "2",
    "shoenumber": "41",
    "winter": "42"
  }
]
HTTP/1.1 404 Not Found
{
  "status": false,
  "message": "Table 'giorgos' does not exist"
}

Thirdparty – Get Record from Custom Table by ID

Retrieves a specific record from the custom table by its ID.

GETyourdomain.com/api/thirdparty/customtable/:table_name/:id

Header

FieldTypeDescription
authtokenStringAuthentication token, generated from admin area

Parameter

FieldTypeDescription
table_nameStringName of the custom database table (exact table name as it exists in the database)
idNumberRecord ID

Success 200

FieldTypeDescription
RecordObjectwith all columns and values

Error 4xx

NameTypeDescription
statusBooleanRequest status
messageStringError message
HTTP/1.1 200 OK
{
  "id": "1",
  "shoenumber": "39",
  "winter": "40"
}
HTTP/1.1 404 Not Found
{
  "status": false,
  "message": "Record not found"
}

Thirdparty – Insert Record into Custom Table

Inserts a new record into the specified custom table. All columns in the request body must exist in the table, otherwise an error will be returned.

POSTyourdomain.com/api/thirdparty/customtable/:table_name

Header

FieldTypeDescription
authtokenStringAuthentication token, generated from admin area
Content-TypeStringapplication/json

Parameter

FieldTypeDescription
table_nameStringName of the custom database table (exact table name as it exists in the database)

Success 200

FieldTypeDescription
statusBooleanRequest status
messageStringSuccess message
idNumberID of the newly created record

Error 4xx

NameTypeDescription
statusBooleanRequest status
messageStringError message
HTTP/1.1 201 Created
{
  "status": true,
  "message": "Record created successfully",
  "id": 5
}
HTTP/1.1 400 Bad Request
{
  "status": false,
  "message": "Column 'invalid_column' does not exist in table 'george'"
}

Thirdparty – Update Record in Custom Table

Updates an existing record in the specified custom table. All columns in the request body must exist in the table, otherwise an error will be returned.

PUTyourdomain.com/api/thirdparty/customtable/:table_name/:id

Header

FieldTypeDescription
authtokenStringAuthentication token, generated from admin area
Content-TypeStringapplication/json

Parameter

FieldTypeDescription
table_nameStringName of the custom database table (exact table name as it exists in the database)
idNumberRecord ID

Success 200

FieldTypeDescription
statusBooleanRequest status
messageStringSuccess message

Error 4xx

NameTypeDescription
statusBooleanRequest status
messageStringError message
HTTP/1.1 200 OK
{
  "status": true,
  "message": "Record updated successfully"
}
HTTP/1.1 400 Bad Request
{
  "status": false,
  "message": "Column 'invalid_column' does not exist in table 'george'"
}

Tickets

Tickets – Add New Ticket

POSTyourdomain.com/api/tickets

Header

FieldTypeDescription
authtokenStringAuthentication token, generated from admin area

Parameter

FieldTypeDescription
subjectStringMandatory Ticket name .
departmentStringMandatory Ticket Department.
contactidStringMandatory Ticket Contact.
useridStringMandatory Ticket user.
project_id (optional)StringOptional Ticket Project.
message (optional)StringOptional Ticket message.
service (optional)StringOptional Ticket Service.
assigned (optional)StringOptional Assign ticket.
cc (optional)StringOptional Ticket CC.
priority (optional)StringOptional Priority.
tags (optional)StringOptional ticket tags.

Success 200

FieldTypeDescription
statusBooleanRequest status.
messageStringTicket add successful.

Error 4xx

NameTypeDescription
statusBooleanRequest status.
messageStringTicket add fail.
HTTP/1.1 200 OK
{
  "status": true,
  "message": "Ticket add successful."
}
HTTP/1.1 404 Not Found
{
  "status": false,
  "message": "Ticket add fail."
}

Tickets – Add reply to a ticket

POSTyourdomain.com/api/tickets/reply/:id

Header

FieldTypeDescription
authtokenStringAuthentication token, generated from admin area

Parameter

FieldTypeDescription
idNumberTicket unique ID.
messageStringMandatory Reply message.
admin (optional)NumberOptional Staff ID (if provided, reply is from staff member).
status (optional)NumberOptional Ticket status after reply (default: 1 for customer, 3 for staff).
cc (optional)StringOptional CC email addresses.
file (optional)FileOptional File attachments.

Success 200

FieldTypeDescription
statusBooleanRequest status.
messageStringTicket Reply Added Successful.
reply_idNumberReply ID.

Error 4xx

NameTypeDescription
statusBooleanRequest status.
messageStringTicket Reply Fail or Invalid Ticket ID.
HTTP/1.1 200 OK
{
  "status": true,
  "message": "Ticket Reply Added Successful.",
  "reply_id": 123
}
HTTP/1.1 404 Not Found
{
  "status": false,
  "message": "Ticket Reply Fail."
}

Tickets – Delete a Ticket

DELETEyourdomain.com/api/delete/tickets/:id

Header

FieldTypeDescription
authtokenStringAuthentication token, generated from admin area

Parameter

FieldTypeDescription
idNumberTicket unique ID.

Success 200

FieldTypeDescription
statusBooleanRequest status.
messageStringTicket Delete Successful.

Error 4xx

NameTypeDescription
statusBooleanRequest status.
messageStringTicket Delete Fail.
HTTP/1.1 200 OK
{
  "status": true,
  "message": "Ticket Delete Successful."
}
HTTP/1.1 404 Not Found
{
  "status": false,
  "message": "Ticket Delete Fail."
}

Tickets – Get Ticket(s)

GETyourdomain.com/api/tickets/:id

Header

FieldTypeDescription
authtokenStringAuthentication token, generated from admin area

Parameter

FieldTypeDescription
id (optional)NumberOptional Ticket unique ID. If not provided, returns all tickets with pagination
page (optional)NumberOptional Page number for pagination (when ID is not provided)Default value: 1
per_page (optional)NumberOptional Number of items per page (min: 1, max: 100, when ID is not provided)Default value: 20

Success 200

FieldTypeDescription
TicketObjectTicket information (when ID provided)
dataObject[]Array of tickets (when ID not provided)
metaObjectPagination metadata (when ID not provided)
  current_pageNumberCurrent page number
  per_pageNumberItems per page
  totalNumberTotal number of tickets
  last_pageNumberLast page number

Error 4xx

NameTypeDescription
statusBooleanRequest status.
messageStringThe id of the Ticket was not found.
HTTP/1.1 200 OK
{
    "id": "7",
    "ticketid": "7",
    "adminreplying": "0",
    "userid": "0",
    "contactid": "0",
    "email": null,
    "name": "Trung bình",
    "department": "1",
    "priority": "2",
    "status": "1",
    "service": "1",
    "ticketkey": "8ef33d61bb0f26cd158d56cc18b71c02",
    "subject": "Ticket ER",
    "message": "Ticket ER",
    "admin": "5",
    "date": "2019-04-10 03:08:21",
    "project_id": "5",
    "lastreply": null,
    "clientread": "0",
    "adminread": "1",
    "assigned": "5",
    "line_manager": "8",
    "milestone": "27",
    ...
}
HTTP/1.1 404 Not Found
{
  "status": false,
  "message": "No data were found"
}

Tickets – Search Ticket Information

GETyourdomain.com/api/tickets/search/:keysearch

Header

FieldTypeDescription
authtokenStringAuthentication token, generated from admin area

Parameter

FieldTypeDescription
keysearchStringSearch keywords.

Success 200

FieldTypeDescription
TicketObjectinformation.

Error 4xx

NameTypeDescription
statusBooleanRequest status.
messageStringThe id of the Ticket was not found.
HTTP/1.1 200 OK
{
  "data": [
    {
      "ticketid": "7",
      "adminreplying": "0",
      "userid": "0",
      "contactid": "0",
      "email": null,
      "name": "Trung bình",
      "department": "1",
      "priority": "2",
      "status": "1",
      "service": "1",
      "ticketkey": "8ef33d61bb0f26cd158d56cc18b71c02",
      "subject": "Ticket ER",
      "message": "Ticket ER",
      "admin": "5",
      "date": "2019-04-10 03:08:21",
      "project_id": "5",
      "lastreply": null,
      "clientread": "0",
      "adminread": "1",
      "assigned": "5",
      "line_manager": "8",
      "milestone": "27",
      ...
    }
  ],
  "meta": {
    "current_page": 1,
    "per_page": 20,
    "total": 45,
    "last_page": 3
  }
}
HTTP/1.1 404 Not Found
{
  "status": false,
  "message": "No data were found"
}

Tickets – Update a ticket

PUTyourdomain.com/api/tickets/:id

Header

FieldTypeDescription
authtokenStringAuthentication token, generated from admin area

Parameter

FieldTypeDescription
subjectStringMandatory Ticket name .
departmentStringMandatory Ticket Department.
contactidStringMandatory Ticket Contact.
useridStringMandatory Ticket user.
priorityStringMandatory Priority.
project_id (optional)StringOptional Ticket Project.
message (optional)StringOptional Ticket message.
service (optional)StringOptional Ticket Service.
assigned (optional)StringOptional Assign ticket.
tags (optional)StringOptional ticket tags.

Success 200

FieldTypeDescription
statusBooleanRequest status.
messageStringTicket Update Successful.

Error 4xx

NameTypeDescription
statusBooleanRequest status.
messageStringTicket Update Fail.
HTTP/1.1 200 OK
{
  "status": true,
  "message": "Ticket Update Successful."
}
HTTP/1.1 404 Not Found
{
  "status": false,
  "message": "Ticket Update Fail."
}

Timesheets

Timesheets – Add New Timesheet

POSTyourdomain.com/api/timesheets/

Header

FieldTypeDescription
authtokenStringAuthentication token, generated from admin area

Error 4xx

NameDescription
  
HTTP/1.1 200 OK
 {
     "status": true,
     "message": "Data Added Successfully"
 }
   HTTP/1.1 404 Not Found
{
    "status": false,
    "error": "Data not Added"    
}

Timesheets – Delete a Timesheet

DELETEyourdomain.com/api/timesheets/:id

Header

FieldTypeDescription
authtokenStringAuthentication token, generated from admin area

Parameter

FieldTypeDescription
ididID for data Deletion.

Error 4xx

NameDescription
  
HTTP/1.1 200 OK
 {
     "status": true,
     "message": "Delete Successful."
 }
   HTTP/1.1 404 Not Found
{
    "status": false,
    "message": "Delete Fail."
}

Timesheets – Request Timesheet Information

GETyourdomain.com/api/timesheets/:id

Header

FieldTypeDescription
authtokenStringAuthentication token, generated from admin area

Parameter

FieldTypeDescription
ididData id ID.

Success 200

FieldTypeDescription
DataObjectInformation

Error 4xx

NameDescription
DataNotFoundThe id of the data was not found.
HTTP/1.1 200 OK
[
    {
        "task_id": "2",
        "start_time": "10:00:00",
        "end_time": "12:00:00",
        "staff_id ": "2",
        "hourly_rate": "5.00",
        "note": "testing note",
    }
]
HTTP/1.1 404 Not Found
{
    "status": false,
    "message": "No data were found"
}

Timesheets – Request all Timesheets

GETyourdomain.com/api/timesheets/

Header

FieldTypeDescription
authtokenStringAuthentication token, generated from admin area

Success 200

FieldTypeDescription
DataObjectInformation

Error 4xx

NameDescription
DataNotFoundThe id of the data was not found.
HTTP/1.1 200 OK
[
    {
        "task_id": "2",
        "start_time": "10:00:00",
        "end_time": "12:00:00",
        "staff_id ": "2",
        "hourly_rate": "5.00",
        "note": "testing note",
    }
]
HTTP/1.1 404 Not Found
{
    "status": false,
    "message": "No data were found"
}

Timesheets – Update a Timesheet

PUTyourdomain.com/api/timesheets/:id

Header

FieldTypeDescription
authtokenStringAuthentication token, generated from admin area

Parameter

FieldTypeDescription
ididID for update data.
HTTP/1.1 200 OK
{
  "status": true,
  "message": "Data Update Successful."
}
    HTTP/1.1 404 Not Found
 {
      "status": false,
      "message": "Data Not Acceptable OR Not Provided"
 }

{
   "status": false,
   "message": "Data Update Fail."
}

🚀 Buy it now!

You can purchase our module by clicking 👉 here.

If you are nterested in other useful Perfex CRM modules, you can check out all available Perfex CRM modules of our team.