The Circumvend API is built on HTTP. Our API is RESTful and it:
Circumvend has published Cards API for customers.
Method: GET, DELETE
Name | Required | Description |
key | true | your API key |
Method: POST
Name | Required | Description |
Content-Type | true | application/json |
key | true | your API key |
Name | Description |
record_per_page | Page size. Default value: 30 |
current_page | Current page number. |
Name | Description |
order_by_field | Order by field. Any field in results. |
order_by_direction | Order by direction. Support values: asc desc |
The where parameter allows you to filter on endpoints and elements that don't have explicit parameters.
Please note: even though the where filter supports complex queries we recommend you
keep them as simple as possible. Long, complex where queries can cause time outs. To ensure your calls
run efficiently against larger
organisations it's a good idea to restrict your queries to simple == operations.
Allowed operations : ==, >, <, !=
Example 1 : Retrieve Locations by postcode.
post_code=='3000'
This would translate to the following URL once percent encoded.
https://api.circumvend.com.au/api/v1/vmms/locations?where=post_code%3D%3D%223000%22
Example 2 : Retrieve results with a date.
date >= '2019-01-01'
Example 3 : Retrieve results with multiple conditions.
first_condition == 'test' and second_condition == 'test'
Description:
Request URL:
https://api.circumvend.com.au/api/v1/vmms/cards
Method:
GET
Allowed Query Parameters:
Name | Format | Required | Description |
card_status | int | false | Card status. Acceptable values are: "1":enabled, "2":disabled, "4":cancelled |
card_type | String | false | Card type. Acceptable values are: "0": Normal, "1":Staff card, "2":Visitor card |
start_date | String(yyyy-MM-dd) | false | Issue date from. |
end_date | String(yyyy-MM-dd) | false | Issue date to. |
search_condition | String | false | This value you can input:Card No, Card holder ID, Holder name or Department. |
Response:
{
"status": "1",
"info": "success",
"page_info": {
"record_per_page": "30",//page size
"total_records": "7", //total records count
"current_page": "1",//current page number
"total_page": "1" //pages count
},
"records": [
{
"card_id": "178862",
"card_no": "0123456789",
"card_amount": "200.0",
"daily_limit": "500.0",
"issue_date": "2017-09-27 16:59:32.0",
"department": "department",
"holder_name": "holderName",
"holder_id": "0",
"card_yype": "Normal",
"card_status": "1",
"prev_card_account_id": "1",
"is_additional": "1",
"card_account_name": "1",
"card_account_id": "1",
"primary_card_no": "1",
"auto_top_up": "0",
},
... ...
]
}
}
Description:
Request URL:
https://api.circumvend.com.au/api/v1/vmms/cards/{card_id}
Method:
GET
Path Parameters
Name | Format | Required | Description |
card_id | int | true | Card id. |
Response :
{
"status": "1",
"info": "success",
"record": [
{
"card_amount": "0.0",
"holder_name": "",
"card_id": "123456",
"daily_limit": "500.0",
"card_type": "Normal",
"card_status": "1",
"department": "",
"issue_date": "01/03/2018 12:34:56",
"holder_id": "",
"card_no": "0123456789"
"prev_card_account_id": "1",
"is_additional": "1",
"card_account_name": "1",
"card_account_id": "1",
"primary_card_no": "1",
"auto_top_up": "0",
}
]
}
Description:
Request URL:
https://api.circumvend.com.au/api/v1/vmms/cards
Method:
POST
Body Parameters (application/json)
Name | Format | Required | Description |
card_no | String | true | Card number. |
global_unique | String | false | Default value is "1". If global_unique = "0" "companyId-" will be prefixed to the card number. e.g. 123456-CARDNO |
daily_limit | String | false | Daily limit.Default value:500.00 . |
card_type | String | false | Card type. Acceptable values are: "0":Normal(Default), "1":Staff Card , "2":Visitor Card”. |
credit | String | false | Card amount. |
holder_name | String | false | Holder name. |
holder_id | String | false | Holder number. |
department | String | false | Department. |
is_additional | String | false | Default value: 0. If create a additional card input 1. |
primary_card_no | String | false | The card no of primary card in your company. |
auto_top_up | String | false | Set if auto top up. Allowed value: "0": false, "1": true. |
Response :
{
"status": "1",
"info": "success",
"id": "719532",//Unique Id of card
"card_no": "1234567890",
"card_amount": "5.5",
"daily_limit": "500.00",
"issue_date": "2017-10-09 14:47:13",
"department": "department",
"holder_name": "holderName",
"holder_id": "2",
"card_status": "1"
"auto_top_up": "0"
}
Description:
Request URL:
https://api.circumvend.com.au/api/v1/vmms/cards/{card_id}
Method:
POST
Path Parameters
Name | Format | Required | Description |
card_id | int | true | Card id. |
Header Parameters
Body Parameters(application/json)
Name | Format | Required | Description |
daily_limit | String | true | Daily limit. |
card_type | String | false | Card type. Acceptable values are: "0":Normal "1":Staff Card , "2":Visitor Card. |
holder_name | String | false | Holder name. |
holder_id | String | false | Holder id. |
department | String | false | department. |
card_status | String | false | 1:enable , 2:disable . |
is_additional | String | false | Default value: 0. If create a additional card input 1. |
primary_card_no | String | false | The card no of primary card in your company. |
auto_top_up | String | false | Set if auto top up. Allowed value: "0": false, "1": true. |
Response :
{
"status": "1",
"info": "success",
"id": "1234",
"card_no": "1234567890",
"card_amount": "5.5",
"daily_limit": "500.00",
"issue_date": "2017-10-09 14:47:13",
"department": "department",
"holder_name": "holderName",
"holder_id": "2",
"card_status": "1",
"card_type": "0"
"auto_top_up": "1"
}
Description:
Request URL:
https://api.circumvend.com.au/api/v1/vmms/cards/{card_id}
Method:
DELETE
Path Parameters
Name | Format | Required | Description |
card_id | int | true | Card id. |
Response :
{
"status": "1"
"info": "success"
}
Description:
Request URL:
https://api.circumvend.com.au/api/v1/vmms/cards/topup
Method:
POST
Header Parameters
Body Parameters
Name | Format | Required | Description |
card_no | String | true | Card Number. |
card_id | String | false | Card id.At least input cardNo or cardId. |
credit | String | true | Top up credit. e.g.”10.00” |
Response :
{
"status": "1",
"info": "success",
"card_id": "427431",
"credit": "10.00"
}
Description:
Request URL:
https://api.circumvend.com.au/api/v1/vmms/card_accounts
Method:
GET
Allowed Query Parameters:
Name | Format | Required | Description |
search_condition | String | false | The value of Card Account Name, First Name, Last Name or Organization. |
Response:
{
"status": "1",
"info": "success",
"page_info": {
"record_per_page": "30",//page size
"total_records": "7", //total records count
"current_page": "1",//current page number
"total_page": "1" //pages count
},
"records": [
{
"card_account_name": "123456",
"password": "",
"email": "",
"first_name": "",
"last_name": "",
"mobile": "",
"card_account_id": "",
"organization": "",
"cards_count": "1",
"state": "1",
},
... ...
]
}
}
Description:
Request URL:
https://api.circumvend.com.au/api/v1/vmms/card_accounts/{card_account_id}
Method:
GET
Path Parameters
Name | Format | Required | Description |
card_account_id | int | true | Card account id. |
Response :
{
"status": "1",
"info": "success",
"record": [
{
"card_account_name": "",
"password": "",
"email": "",
"first_name": "",
"last_name": "",
"mobile": "",
"card_account_id": "",
"organization": "",
"cards_count": "1",
"state": "1",
}
]
}
Description:
Request URL:
https://api.circumvend.com.au/api/v1/vmms/card_accounts
Method:
POST
Header Parameters
Body Parameters (application/json)
Name | Format | Required | Description |
card_account_name | String | true | Card account name.Unique in vmms system. |
password | String | true | Password. |
repeat_password | String | true | Repeat password,must match with the password. |
String | false | Email address. | |
mobile | String | false | Mobile number of card account. |
first_name | String | false | First name of card account. |
last_name | String | false | Last name of card account. |
organization | String | false | Organization of card account. |
Response :
{
"status": "1",
"info": "success",
"id": "123456",//Card account ID.
"card_account_name": "",
"password": "",
}
Description:
Request URL:
https://api.circumvend.com.au/api/v1/vmms/card_accounts/{card_account_id}
Method:
POST
Path Parameters
Name | Format | Required | Description |
card_account_id | int | true | Card account id. |
Header Parameters
Body Parameters(application/json)
Name | Format | Required | Description |
password | String | false | Password. |
repeat_password | String | false | Repeat password,must match with the password. |
String | false | Email address. | |
mobile | String | false | Mobile number of card account. |
first_name | String | false | First name of card account. |
last_name | String | false | Last name of card account. |
organization | String | false | Organization of card account. |
Response :
{
"status": "1",
"info": "success",
"id": "1234",
}
Description:
Request URL:
https://api.circumvend.com.au/api/v1/vmms/cardvends
Method:
GET
Query Parameters:
Name | Format | Required | Description |
start_date | String(dd/MM/yyyy) | false | Default value:current date. |
end_date | String(dd/MM/yyyy) | false | Default value:current date. |
card_type | String | false | Card type.Acceptable values are: "0": Normal, "1":Staff card, "2":Visitor card , "3": Credit card. |
imei | String | false | Imei number. |
machine_id | String | false | Machine ID. |
start_time | String(dd/MM/yyyy HH:mm:ss) | false | e.g. 03/10/2019 10:11:12 |
end_time | String(dd/MM/yyyy HH:mm:ss) | false | e.g. 04/03/2020 10:11:12 |
sum_only | String | false | Return vends summary, if sum_only = 1. |
search_condition | String | false | Input anything like Vend ID, Machine ID, IMEI, Card No, Card holder ID, Holder name or Departmentor. |
Response :
Name | Format | Required | Description |
vend_type | String | false | 0: contactless credit card, 1: contact credit card, 2:RFID, 10: Circumpay balance, 11: Circumpay membership card, 12: Circumpay credit card |
{
"status": "1",
"info": "success",
"page_info": {
"total_records": "5",
"record_per_page": "30",
"total_page": "1",
"current_page": "1"
},
"records": [
{
"unit_price": "3.0",
"product_name": "Mt Franklin Water",
"card_no": "123456******1234",
"vend_id": "1",
"coil_no": "2",
"vend_time": "12/06/2018 02:25:05",
"machine_id": "3",
"imei": "0123456789abcdef",
"item_no": "4",
"sur_charge": "0.3",
"vend_type": "0"
},
... ...
]
}
Description:
Request URL:
https://api.circumvend.com.au/api/v1/vmms/cardvends
Method:
GET
Query Parameters
Name | Format | Required | Description |
action | String | true | action=refund |
vend_id | String | false | Cardvend ID. |
txn_id | String | false | Transaction ID of vend. |
imei | String | false | DTU IMEI number. |
Usage:
1. Refund by vend_id:
https://api.circumvend.com.au/api/v1/vmms/cardvends?action=refund&vend_id=123456
2. Refund by imei and txn_id:
https://api.circumvend.com.au/api/v1/vmms/cardvends?action=refund&imei=A123456789&txn_id=txnid20240624105533
Response :
{
"status": "1",
"info": "success"
}
Description:
Request URL:
https://api.circumvend.com.au/api/v1/vmms/locations
Method:
GET
Query Parameters:
Name | Format | Required | Description |
Response :
{
"status": "1",
"info": "success",
"page_info": {
"total_records": "3",
"record_per_page": "50",
"total_page": "1",
"current_page": "1"
},
"records": [
{
"fax": "",
"location_id": "",
"state": "",
"location_name": "",
"post_code": "",
"office_phone": "",
"contact": "",
"city": "",
"email": "",
"address": "",
"mobile": ""
"collection": "0.0"
"product_full": "0.0"
"product_empty": "0"
"product_low": "0"
"product_normal": "0"
},
... ...
]
}
Description:
Request URL:
https://api.circumvend.com.au/api/v1/vmms/locations/{location_id}
Method:
GET
Path Parameters:
Name | Format | Required | Description |
location_id | int | true | Location id. |
Response :
{
"status": "1",
"info": "success",
"record":[
{
"fax": "",
"location_id": "",
"state": "",
"location_name": "",
"post_code": "",
"office_phone": "",
"contact": "",
"city": "",
"email": "",
"address": "",
"mobile": ""
"collection": "0.0"
"product_full": "0.0"
"product_empty": "0"
"product_low": "0"
"product_normal": "0"
}
]
}
Description:
Request URL:
https://api.circumvend.com.au/api/v1/vmms/locations
Method:
POST
Header Parameters:
Body Parameters:
Name | Format | Required | Description |
location_name | String | true | Unique Location name in your company. |
contact | String | false | Contact |
address | String | false | Location address. |
city | String | false | location city. |
post_code | String | false | Location postcode. |
state | String | false | Location state. |
country | String | false | Location country. |
office_phone | String | false | Office phone number of contact. |
home_phone | String | false | Home phone number of contact. |
mobile | String | false | Mobile number of contact. |
fax | String | false | Fax of contact. |
String | false | Email of contact. | |
notes | String | false | Notes |
Response :
{
"status": "1",
"info": "success",
"id": "1234",
"fax": "",
"location_id": "",
"state": "",
"location_name": "",
"post_code": "",
"office_phone": "",
"contact": "",
"city": "",
"email": "",
"address": "",
"mobile": ""
}
Description:
Request URL:
https://api.circumvend.com.au/api/v1/vmms/locations/{location_id}
Method:
POST
Header Parameters :
Path Parameters:
Name | Format | Required | Description |
location_id | int | true | Location id. |
Body Parameters:
Name | Format | Required | Description |
location_name | String | true | Unique Location name in your company. |
contact | String | false | Contact |
address | String | false | Location address. |
city | String | false | location city. |
post_code | String | false | Location postcode. |
state | String | false | Location state. |
country | String | false | Location country. |
office_phone | String | false | Office phone number of contact. |
home_phone | String | false | Home phone number of contact. |
mobile | String | false | Mobile number of contact. |
fax | String | false | Fax of contact. |
String | false | Email of contact. | |
notes | String | false | Notes |
Response :
{
"status": "1",
"info": "success",
"fax": "",
"location_id": "",
"state": "",
"location_name": "",
"post_code": "",
"office_phone": "",
"contact": "",
"city": "",
"email": "",
"address": "",
"mobile": ""
}
Description:
Request URL:
https://api.circumvend.com.au/api/v1/vmms/locations/{location_id}
Method:
DELETE
Path Parameters
Name | Format | Required | Description |
location_id | int | true | Location id. |
Response :
{
"status": "1",
"info": "success"
}
Description:
Request URL:
https://api.circumvend.com.au/api/v1/vmms/routes
Method:
GET
Query Parameters:
Name | Format | Required | Description |
Response :
{
"status": "1",
"info": "success",
"page_info": {
"total_records": "1",
"record_per_page": "30",
"total_page": "1",
"current_page": "1"
},
"records": [
{
"route_id": "3",
"driver": "driver",
"description": "description",
"route_name": "test route name"
},
... ...
]
}
Description:
Request URL:
https://api.circumvend.com.au/api/v1/vmms/routes/{route_id}
Method:
GET
Path Parameters:
Name | Format | Required | Description |
route_id | int | true | Route id. |
Response :
{
"status": "1",
"info": "success",
"record": [
{
"route_id": "",
"driver": "",
"description": "",
"route_name": ""
}
]
}
Description:
Request URL:
https://api.circumvend.com.au/api/v1/vmms/routes
Method:
POST
Header Parameters :
Body Parameters:
Name | Format | Required | Description |
route_name | String | true | Unique route name in your company. |
driver | String | false | Route driver. |
description | String | false | Route description. |
Response :
{
"status": "success",
"route_id": "",
"route_name": "",
"driver": "",
"description": ""
}
Description:
Request URL:
https://api.circumvend.com.au/api/v1/vmms/routes/{route_id}
Method:
POST
Header Parameters:
Path Parameters:
Name | Format | Required | Description |
route_id | int | true | Route id. |
Body Parameters:
Name | Format | Required | Description |
route_name | String | true | Unique route name in your company. |
driver | String | false | Route driver. |
description | String | false | Route description. |
Response :
{
"status": "1",
"info": "success",
"id": "",
"driver": "",
"description": "",
"route_name": ""
}
Description:
Request URL:
https://api.circumvend.com.au/api/v1/vmms/routes/{route_id}
Method:
DELETE
Path Parameters
Name | Format | Required | Description |
route_id | int | true | Route Id. |
Response :
{
"status": "0",
"info": "fail"
}
Description:
Request URL:
https://api.circumvend.com.au/api/v1/vmms/machines
Method:
GET
Allowed Query Parameters:
Name | Format | Required | Description |
machine_status | int | false | Default show all machine. Acceptable values are: “0”:Offline , “1”:Online , “2”:Lost Contact |
location_name | String | false | Location name of machine. |
route_name | String | false | Route name of machine. |
machine_model | String | false | Machine type name. |
search_condition | String | false | Input machine id or serial number or imei number. |
Response :
{
"status": "1",
"info": "success",
"page_info": {
"total_records": "50",
"record_per_page": "30",
"total_page": "2",
"current_page": "1"
},
"records": [
{
"machine_model_id": "109",
"purchase_date": "07/08/2018 00:00:00",
"location_name": "test080608",
"yearly_value": "0.0",
"route_name": "testroute",
"serial_no": "machinetest",
"restock_value": "0.0",
"yesterday_value": "0.0",
"route_id": "2616",
"machine_id": "11243",
"last_restock": "",
"install_date": "07/08/2018 00:00:00",
"location_id": "14447",
"today_value": "0.0",
"monthly_value": "0.0",
"imei": "01234567890",
"machine_status": "0",
"weekly_value": "0.0",
"signal": "31",
"machine_model": "Bianchi BVM 671",
"last_report": ""
"temperature": "36.0"
"roi": "0.0"
"purchase_price": "6000.0"
"dep_rate": "0.0"
"current_value": "128.0"
"weight": "66.0"
"place": ""
},
... ...
]
}
Description:
Request URL:
https://api.circumvend.com.au/api/v1/vmms/machines/{machine_id}
Method:
GET
Path Parameters:
Name | Format | Required | Description |
machine_id | int | true | Machine id. |
Response :
{
"status": "1",
"info": "success",
"record": [
{
"machine_model_id": "109",
"purchase_date": "07/08/2018 00:00:00",
"location_name": "test080608",
"yearly_value": "0.0",
"route_name": "testroute",
"serial_no": "machinetest",
"restock_value": "0.0",
"yesterday_value": "0.0",
"route_id": "2616",
"machine_id": "11243",
"last_restock": "",
"install_date": "07/08/2018 00:00:00",
"location_id": "14447",
"today_value": "0.0",
"monthly_value": "0.0",
"imei": "01234567890",
"machine_status": "0",
"weekly_value": "0.0",
"signal": "31",
"machine_model": "Bianchi BVM 671",
"last_report": ""
"temperature": "36.0"
"roi": "0.0"
"purchase_price": "6000.0"
"dep_rate": "0.0"
"current_value": "128.0"
"weight": "66.0"
"place": ""
}
]
}
Description:
Request URL:
https://api.circumvend.com.au/api/v1/vmms/machines
Method:
POST
Header Parameters:
Body Parameters:
Name | Format | Required | Description |
serial_no | String | true | Unique serial number in your company. |
machine_model_id | String | true | Machine model id. |
location_id | String | true | One of exist location id in your company. |
route_id | String | true | One of exist route id in your company. |
imei | String | false | Unlinked imei number. |
Response :
{
"status": "1",
"info": "success",
"id": "12345",
"machine_model_id": "6",
"route_id": "123",
"location_id": "123",
"serial_no": "testMachineserial_no"
}
Description:
Request URL:
https://api.circumvend.com.au/api/v1/vmms/machines/{machine_id}
Method:
POST
Header Parameters:
Path Parameters:
Name | Format | Required | Description |
machine_id | int | true | Machine id |
Body Parameters:
Name | Format | Required | Description |
serial_no | String | false | Unique serial number in your company. |
machine_model_id | String | false | Machine model id. |
location_id | String | false | One of exist location id in your company. |
route_id | String | false | One of exist route id in your company. |
imei | String | false | Unlinked imei number. |
Response :
{
"status": "1",
"info": "success",
"id": "",
"machine_model_id": "",
"route_id": "",
"location_id": "",
"imei": ""
}
Description:
Request URL:
https://api.circumvend.com.au/api/v1/vmms/machines/{machine_id}
Method:
DELETE
Path Parameters
Name | Format | Required | Description |
machine_id | int | true | Machine Id. |
Response :
{
"status": "1",
"info": "success"
}
Description:
Request URL:
https://api.circumvend.com.au/api/v1/vmms/coils
Method:
GET
Query Parameters:
Name | Format | Required | Description |
machine_id | int | true | You must set machine_id to receive coils. |
Response :
{
"status": "1",
"info": "success",
"page_info": {
"total_records": "1",
"record_per_page": "30",
"total_page": "1",
"current_page": "1"
},
"records": [
{
"current_level": "3",
"machine_id": "12345",
"par_level": "3",
"product_id": "123",
"price": "10.0",
"coil_id": "123456",
"alarm_level": "1",
"last_life_vends": "0",
"last_ife_value": "0.0",
"last_vend_time": "",
"coil_no": "1",
"product_name": "test product"
},
... ...
]
}
Description:
Request URL:
https://api.circumvend.com.au/api/v1/vmms/coils/{coil_id}
Method:
GET
Path Parameters:
Name | Format | Required | Description |
coil_id | int | true | Coil id. |
Response :
{
"status": "1",
"info": "success",
"record": [
{
"current_level": "",
"machine_id": "",
"par_level": "",
"product_id": "",
"price": "",
"coilId": "",
"alarm_level": "",
"last_life_vends": "",
"last_ife_value": "",
"last_vend_time": "",
"coil_no": "",
"product_name": ""
}
]
}
Description:
Request URL:
https://api.circumvend.com.au/api/v1/vmms/coils
Method:
POST
Header Parameters:
Body Parameters:
Name | Format | Required | Description |
machine_id | String | true | Valid machine id in your company. |
product_id | String | true | Valid product id in your company. |
price | String | true | Product price. |
coil_no | String | true | Unnique coil no in machine. |
current_level | String | true | Current level,need equal or less than Par level. |
alarm_level | String | true | Alarm level,must bigger than 0 and less than Par level. |
par_level | String | true | Par level. |
Response :
{
"status": "1",
"info": "success",
"id": "",
"current_level": "",
"machine_id": "",
"product_id": "",
"par_level": "",
"price": "",
"alarm_level": "",
"coil_no": ""
}
Description:
Request URL:
https://api.circumvend.com.au/api/v1/vmms/coils/{coil_id}
Method:
POST
Header Parameters :
Path Parameters:
Name | Format | Required | Description |
coil_id | int | true | coil id. |
Body Parameters:
Name | Format | Required | Description |
product_id | String | false | Valid product id in your company. |
price | String | false | Product price. |
coil_no | String | false | Unnique coil no in machine. |
current_level | String | false | Current level,need equal or less than Par level. |
alarm_level | String | false | Alarm level,must bigger than 0 and less than Par level. |
par_level | String | false | Par level. |
Response :
{
"status": "1",
"info": "success",
"id": "",
"current_level": "",
"product_id": "",
"par_level": "",
"price": "",
"alarm_level": "",
"coil_no": ""
}
Description:
Request URL:
https://api.circumvend.com.au/api/v1/vmms/coils/{coil_id}
Method:
DELETE
Produces :
application/json
Path Parameters
Name | Format | Required | Description |
coil_id | int | true | coil id. |
Response :
{
"status": "success"
}
Description:
Request URL:
https://api.circumvend.com.au/api/v1/vmms/coils?coil_alarm=1
Method:
GET
Query Parameters:
Name | Format | Required | Description |
location_id | int | true | Filter coil with location. |
route_id | int | true | Filter coil with route. |
show_empty_coils | int | true | Set if show empty coils. Default value: 0; Acceptable values: 0, 1 |
show_low_coils | int | true | Set if show low coils. Default value: 0; Acceptable values: 0, 1 |
Response :
{
"status": "1",
"info": "success",
"page_info": {
"total_records": "1",
"record_per_page": "30",
"total_page": "1",
"current_page": "1"
},
"records": [
{
"current_level": "3",
"machine_id": "12345",
"par_level": "3",
"product_id": "123",
"price": "10.0",
"coil_id": "123456",
"alarm_level": "1",
"last_life_vends": "0",
"last_ife_value": "0.0",
"last_vend_time": "",
"coil_no": "1",
"product_name": "test product"
"machine_place": "machine place"
"location_name": "Test location"
"product_upc_no": "000000"
},
... ...
]
}
Description:
Request URL:
https://api.circumvend.com.au/api/v1/vmms/machine_models
Method:
GET
Query Parameters:
Name | Format | Required | Description |
Produces :
application/json
Response :
{
"status": "1",
"info": "success",
"page_info": {
"total_records": "190",
"record_per_page": "30",
"total_page": "7",
"current_page": "1"
},
"records": [
{
"machine_model": "",
"machine_model_id": ""
},
... ...
]
}
Description:
Request URL:
https://api.circumvend.com.au/api/v1/vmms/machine_models/{machine_model_id}
Method:
GET
Path Parameters:
Name | Format | Required | Description |
machine_model_id | int | true | Machine model id |
Response :
{
"status": "1",
"info": "success",
"record": [
{
"machine_model_id": "",
"machine_model": "Bay Wash 100"
}
]
}
Description:
Request URL:
https://api.circumvend.com.au/api/v1/vmms/user
Method:
GET
Allowed Query Parameters:
Name | Format | Required | Description |
search_condition | String | false | Input user name or first name or last name. |
Response :
{
"status": "1",
"info": "success",
"page_info": {
"total_records": "20",
"record_per_page": "30",
"total_page": "1",
"current_page": "1"
},
"records": [
{
"email": "",
"country": "",
"postcode": "",
"state": "",
"address": "",
"fax_no": "",
"mobile": "",
"home_phone": "",
"office_phone": "",
"last_name": "",
"first_name": "",
"user_name": "",
"user_id": ""
},
... ...
]
}
Description:
Request URL:
https://api.circumvend.com.au/api/v1/vmms/user/{user_id}
Method:
GET
Path Parameters:
Name | Format | Required | Description |
user_id | int | true | User id. |
Response :
{
"status": "1",
"info": "success",
"record": [
{
"email": "",
"country": "",
"postcode": "",
"state": "",
"address": "",
"fax_no": "",
"mobile": "",
"home_phone": "",
"office_phone": "",
"last_name": "",
"first_name": "",
"user_name": "",
"user_id": ""
}
]
}
Description:
Request URL:
https://api.circumvend.com.au/api/v1/vmms/user
Method:
POST
Header Parameters:
Body Parameters:
Name | Format | Required | Description |
account_name | String | true | Unique user name in our system. |
password | String | true | Password. |
first_name | String | true | First name of user. |
last_name | String | true | Last name of user. |
user_role | String | false | User role.Acceptable values are: “1”:Administrator, “2”:Cashless Administrator,”3”:Guest(Default) , “4”:Service Man . |
office_phone | String | false | Office phone of user. |
home_phone | String | false | Home phone of user. |
mobile | String | false | Moblie number of user. |
fax | String | false | Fax number of user. |
address | String | false | Address . |
state | String | false | State . |
country | String | false | Country . |
postcode | String | false | Postcode . |
String | false | Email address of user. |
Response :
{
"status": "1",
"info": "success",
"id": "1234",
"country": "country",
"home_phone": "home_phone",
"address": "address",
"user_name": "",
"postcode": "postcode",
"mobile": "mobile",
"last_name": "last_name",
"office_phone": "office_phone",
"user_role": "1",
"password": "password",
"account_name": "accoune_name",
"state": "state",
"fax": "fax_no",
"first_name": "first_name",
"email": "email@test.com"
}
Description:
Request URL:
https://api.circumvend.com.au/api/v1/vmms/user/{user_id}
Method:
POST
Header Parameters:
Path Parameters:
Name | Format | Required | Description |
user_id | int | true | User id |
Body Parameters:
Name | Format | Required | Description |
first_name | String | false | First name of user. |
last_name | String | false | Last name of user. |
user_role | String | false | User role.Acceptable values are: “1”:Administrator, “2”:Cashless Administrator,”3”:Guest(Default) , “4”:Service Man . |
office_phone | String | false | Office phone of user. |
home_phone | String | false | Home phone of user. |
mobile | String | false | Moblie number of user. |
fax | String | false | Fax number of user. |
address | String | false | Address . |
state | String | false | State . |
country | String | false | Country . |
postcode | String | false | Postcode . |
String | false | Email address of user. |
Can not update account name.
Response :
{
"status": "1",
"info": "success",
"id": "1234",
"country": "new country",
"home_phone": "new1 home_phone",
"address": "new address",
"user_name": "",
"postcode": "new postcode",
"mobile": "new mobile",
"last_name": "new last_name",
"office_phone": "new office_phone",
"user_role": "2",
"state": "new state",
"fax": "new fax_no",
"first_name": "new first_name",
"email": "email@test.com"
}
Description:
Request URL:
https://api.circumvend.com.au/api/v1/vmms/user/{user_id}
Method:
DELETE
Path Parameters
Name | Format | Required | Description |
user_id | int | true | User Id. |
Response :
{
"status": "1",
"info": "success"
}
Description:
Request URL:
https://api.circumvend.com.au/api/v1/vmms/user/login
Method:
POST
Header Parameters:
Body Parameters:
Name | Format | Required | Description |
user_name | String | true | User name. |
password | String | true | Password. |
User login does not require a “key” in the http header.
Response :
{
"status": "1",
"info": "success"
"api_key": "API key"
}
Description:
Request URL:
https://api.circumvend.com.au/api/v1/vmms/company
Method:
GET
Response :
{
"status": "1",
"info": "success",
"record": [
{
"country": "AUS",
"office_phone": "office phone",
"state": "VIC",
"post_code": "3194",
"city": "Mentone",
"address": "Suite 1.02, 3 Joseph Avenue",
"contact": "Contact name",
"company_name": "Circumtec",
"company_id": "2",
"moblie": "mobile",
"fax": "new fax",
"email": "test@mail.com",
"notes": "this is the notes",
"abn": "new abn",
"homePhone": "new home phone"
}
]
}
Description:
Request URL:
https://api.circumvend.com.au/api/v1/vmms/company
Method:
POST
Header Parameters:
Body Parameters:
Name | Format | Required | Description |
company_name | String | false | Company name. |
abn | String | false | Abn . |
contact | String | false | Contact of company. |
office_phone | String | false | Office phone of company. |
home_phone | String | false | Home phone of company. |
mobile | String | false | Moblie number of company. |
fax | String | false | Fax number of company. |
address | String | false | Address of company. |
city | String | false | State . |
state | String | false | State . |
country | String | false | Country . |
postcode | String | false | Postcode . |
String | false | Email address of user. | |
notes | String | false | Notes . |
Response :
{
"status": "1",
"info": "success",
"id": "",
"home_phone": "new home phone",
"country": "new country",
"notes": "this is the notes",
"address": "new address",
"city": "new city",
"user_name": "DEMO",
"mobile": "new mobile",
"postcode": "new postcode",
"abn": "new abn",
"office_phone": "new office phone",
"company_name": "new company name",
"contact": "new contact",
"state": "new state",
"fax": "new fax",
"email": "test@mail.com"
}
Description:
Request URL:
https://api.circumvend.com.au/api/v1/vmms/category
Method:
GET
Query Parameters:
Name | Format | Required | Description |
Response :
{
"status": "1",
"info": "success",
"page_info": {
"total_records": "15",
"record_per_page": "30",
"total_page": "1",
"current_page": "1"
},
"records": [
{
"category_id": "107226",
"category_name": "Soft Drink Cans",
"note": "",
"category_image": "/img/10400/producttype/producttype_47361.jpeg",
"is_system": ""
},
... ...
]
}
Description:
Request URL:
https://api.circumvend.com.au/api/v1/vmms/category/{category_id}
Method:
GET
Path Parameters:
Name | Format | Required | Description |
category_id | int | true | Category id. |
Response :
{
"status": "1",
"info": "success",
"record":[
{
"category_id": "107226",
"category_name": "Soft Drink Cans",
"note": "",
"category_image": "/img/10400/producttype/producttype_47361.jpeg",
"is_system": ""
}
]
}
Description:
Request URL:
https://api.circumvend.com.au/api/v1/vmms/category
Method:
POST
Header Parameters:
Body Parameters:
Name | Format | Required | Description |
category_name | String | true | Unique category name in your company. |
note | String | false | Note |
category_image | String | false | Image url. |
Response :
{
"status": "1",
"info": "success",
"record":[
{
"category_id": "123456",
"category_name": "New category name",
"note": "note...",
"category_image": "/img/10400/producttype/producttype_47361.jpeg",
"is_system": ""
}
]
}
Description:
Request URL:
https://api.circumvend.com.au/api/v1/vmms/category/{category_id}
Method:
POST
Header Parameters :
Path Parameters:
Name | Format | Required | Description |
category_id | int | true | Category id. |
Body Parameters:
Name | Format | Required | Description |
Name | Format | Required | Description |
category_name | String | false | Unique category name in your company. |
note | String | false | Note |
category_image | String | false | Image url. |
Response :
{
"status": "1",
"info": "success",
"record":[
{
"category_id": "123456",
"category_name": "New category name",
"note": "note...",
"category_image": "/img/10400/producttype/producttype_47361.jpeg",
"is_system": ""
}
]
}
Description:
Request URL:
https://api.circumvend.com.au/api/v1/vmms/category/{category_id}
Method:
DELETE
Path Parameters
Name | Format | Required | Description |
category_id | int | true | Category id. |
Response :
{
"status": "1",
"info": "success"
}
Description:
Request URL:
https://api.circumvend.com.au/api/v1/vmms/brands
Method:
GET
Query Parameters:
Name | Format | Required | Description |
Response :
{
"status": "1",
"info": "success",
"page_info": {
"total_records": "15",
"record_per_page": "30",
"total_page": "1",
"current_page": "1"
},
"records": [
{
"brand_id": "197005",
"brand_name": "Brand Name",
"note": "",
"brand_image": "/images/nopic.gif",
"is_system": ""
},
... ...
]
}
Description:
Request URL:
https://api.circumvend.com.au/api/v1/vmms/brands/{brand_id}
Method:
GET
Path Parameters:
Name | Format | Required | Description |
brand_id | int | true | Brand id. |
Response :
{
"status": "1",
"info": "success",
"record":[
{
"brand_id": "197005",
"brand_name": "Brand Name",
"note": "",
"brand_image": "/images/nopic.gif",
"is_system": ""
}
]
}
Description:
Request URL:
https://api.circumvend.com.au/api/v1/vmms/brands
Method:
POST
Header Parameters:
Body Parameters:
Name | Format | Required | Description |
brand_name | String | true | Unique brand name in your company. |
note | String | false | Note |
brand_image | String | false | Image url. |
Response :
{
"status": "1",
"info": "success",
"record":[
{
"brand_id": "123456",
"brand_name": "New brand name",
"note": "note...",
"brand_image": "/img/nopic.jpeg",
"is_system": ""
}
]
}
Description:
Request URL:
https://api.circumvend.com.au/api/v1/vmms/brands/{brand_id}
Method:
POST
Header Parameters :
Path Parameters:
Name | Format | Required | Description |
brand_id | int | true | Brand id. |
Body Parameters:
Name | Format | Required | Description |
brand_name | String | false | Unique brand name in your company. |
note | String | false | Note |
brand_image | String | false | Image url. |
Response :
{
"status": "1",
"info": "success",
"record":[
{
"brand_id": "123456",
"brand_name": "New category name",
"note": "note...",
"brand_image": "/img/10400/producttype/producttype_47361.jpeg",
"is_system": ""
}
]
}
Description:
Request URL:
https://api.circumvend.com.au/api/v1/vmms/brands/{brand_id}
Method:
DELETE
Path Parameters
Name | Format | Required | Description |
brand_id | int | true | Brand id. |
Response :
{
"status": "1",
"info": "success"
}
Description:
Request URL:
https://api.circumvend.com.au/api/v1/vmms/products
Method:
GET
Query Parameters:
Name | Format | Required | Description |
virtual_product | int | false | If virtual_product=1, return all virtual products(Membership card). Default value is 0; |
Response :
{
"status": "1",
"info": "success",
"page_info": {
"record_per_page": "30",
"total_records": "7",
"current_page": "1",
"total_page": "1"
},
"records": [
{
"product_id": "473474",
"brand_id": "177357",
"product_type_id": "107228",
"upc_no": "",
"product_name": "Product name",
"supplier_id": "0",
"price": "1.0",
"size": "",
"in_stock": "60",
"reorder": "0",
"min_order": "0",
"bulk_qty": "0",
"shelf_life": "20",
"alarm_level": "0",
"supplier_name": "supplier name",
"large_image": "/images/nopic.gif",
"daily_avg": "0.0",
"brand_image": "/images/nopic.gif",
"category_image": "/images/nopic.gif",
"description": "description"
},
... ...
]
}
}
Description:
Request URL:
https://api.circumvend.com.au/api/v1/vmms/products/{product_id}
Method:
GET
Path Parameters:
Name | Format | Required | Description |
product_id | int | true | Product id. |
Response :
{
"status": "1",
"info": "success",
"page_info": {
"record_per_page": "1",
"total_records": "1",
"current_page": "1",
"total_page": "1"
},
"records": [
{
"product_id": "473474",
"brand_id": "177357",
"product_type_id": "107228",
"upc_no": "",
"product_name": "Product name",
"supplier_id": "0",
"price": "1.0",
"size": "",
"in_stock": "60",
"reorder": "0",
"min_order": "0",
"bulk_qty": "0",
"shelf_life": "20",
"alarm_level": "0",
"supplier_name": "supplier name",
"large_image": "/images/nopic.gif",
"daily_avg": "0.0",
"brand_image": "/images/nopic.gif",
"category_image": "/images/nopic.gif",
"description": "description"
},
... ...
]
}
}
Description:
Request URL:
https://api.circumvend.com.au/api/v1/vmms/transactions
Method:
GET
Query Parameters:
Name | Format | Required | Description |
start_date | string(dd/MM/yyyy) | false | Default value: current date. |
end_date | string(dd/MM/yyyy) | false | Default value:current date. |
card_no | string | false | Query with card number. |
card_account_id | int | false | Query with card account id. |
Response :
{
"status": "1",
"info": "success",
"page_info": {
"record_per_page": "30",
"total_records": "7",
"current_page": "1",
"total_page": "1"
},
"records": [
{
"transaction_id": "666819",
"card_id": "8660105",
"card_no": "test122501",
"card_type": "Normal",
"description": "description",
"card_account_id": "17600354",
"credit_time": "19/01/2021 11:48:40",
"status": "0",
"balance": "60.00",
"credit": "0.0",
},
... ...
]
}
}
Description:
Request URL:
https://api.circumvend.com.au/api/v1/vmms/dtus
Method:
GET
Query Parameters:
Name | Format | Required | Description |
no_machine | string | false | Allowed value: "0": , "1"; if no_machine = 0, return all dtus not linked to machine; |
is_linked | string | false | Allowed value: "0": , "1"; |
dtu_model | string | false | Dtu model field. |
update_flag | string | false | Update flag field. |
firmware_ver | string | false | Firmware version of dtu. |
Response :
{
"status": "1",
"info": "success",
"page_info": {
"record_per_page": "30",
"total_records": "7",
"current_page": "1",
"total_page": "1"
},
"records": [
{
"dtu_id": "26666",
"machine_id": "18420",
"imei": "867377026312235",
"ip_address": "10.99.236.238",
"dtu_state": "1",
"report_interval": "2",
"serial_no": "",
"model_no": "cv408",
"build_standard": "0",
"location": "",
"asset_no": "",
"decimal_point": "0.0",
"currency_code_no": "0",
"currency_code_name": "",
"vmc_serial": "",
"vmc_model": "",
"vms_build_std": "",
"heartbeat_interval": "1440",
"apn": "",
"firmware_ver": "1.0.21",
"signal": "10",
"last_report": "",
"imsi": "",
"ccid": "",
"company_id": "",
"mode": "0"
},
... ...
]
}
}
Description:
Request URL:
https://api.circumvend.com.au/api/v1/vmms/dtus/{dtu_id}
Method:
GET
Path Parameters:
Name | Format | Required | Description |
dtu_id | int | true | Dtu id. |
Response :
{
"status": "1",
"info": "success",
"page_info": {
"record_per_page": "1",
"total_records": "1",
"current_page": "1",
"total_page": "1"
},
"records": [
{
"dtu_id": "26666",
"machine_id": "18420",
"imei": "867377026312235",
"ip_address": "10.99.236.238",
"dtu_state": "1",
"report_interval": "2",
"serial_no": "",
"model_no": "cv408",
"build_standard": "0",
"location": "",
"asset_no": "",
"decimal_point": "0.0",
"currency_code_no": "0",
"currency_code_name": "",
"vmc_serial": "",
"vmc_model": "",
"vms_build_std": "",
"heartbeat_interval": "1440",
"apn": "",
"firmware_ver": "1.0.21",
"signal": "10",
"last_report": "",
"imsi": "",
"ccid": "",
"company_id": "",
"mode": "0"
},
... ...
]
}
}
Description:
Request URL:
https://api.circumvend.com.au/api/v1/vmms/dtus?imei={imei}&action={action}
Method:
GET
Path Parameters:
Name | Format | Required | Description |
imei | String | true | IMEI of DTU |
action | String | true | action of the command, |
Supported actions:
Name | Format | Description | Sample |
dex | String | Report Dex | https://api.circumvend.com.au/api/v1/vmms/dtus?imei=123456&action=dex |
restock_only | String | Resotck the machine which reset current level of all coils to the PAR level | https://api.circumvend.com.au/api/v1/vmms/dtus?imei=123456&action=restock_only |
restock | String | Same as restock_only action, plus create a collection report | https://api.circumvend.com.au/api/v1/vmms/dtus?imei=123456&action=restock |
remote_credit | String | Send a credit to DTU, the card no can be any valid card under cashless->Card List menu in your account. | https://api.circumvend.com.au/api/v1/vmms/dtus?imei=123456&action=remote_credit&card_no=FREE_CREDIT&credit=1400 |
check_status | String | Check the status of DTU is 'idle' or 'busy'. API will returns: { "status": "1", "info": "idle" } or { "status": "0", "info": "busy" }. The checking process may take up to 20 seconds. | https://api.circumvend.com.au/api/v1/vmms/dtus?imei=123456&action=check_status |
Response :
{
"status": "1",
"info": "success",
"page_info": {
"record_per_page": "1",
"total_records": "1",
"current_page": "1",
"total_page": "1"
},
"records": [
{
"dtu_id": "26666",
"machine_id": "18420",
"imei": "867377026312235",
"ip_address": "10.99.236.238",
"dtu_state": "1",
"report_interval": "2",
"serial_no": "",
"model_no": "cv408",
"build_standard": "0",
"location": "",
"asset_no": "",
"decimal_point": "0.0",
"currency_code_no": "0",
"currency_code_name": "",
"vmc_serial": "",
"vmc_model": "",
"vms_build_std": "",
"heartbeat_interval": "1440",
"apn": "",
"firmware_ver": "1.0.21",
"signal": "10",
"last_report": "",
"imsi": "",
"ccid": "",
"company_id": "",
"mode": "0"
},
... ...
]
}
}
Description:
Request URL:
https://api.circumvend.com.au/api/v1/vmms/reports
Method:
GET
Query Parameters:
Name | Format | Required | Description |
report_type | string | true | report_type = machine_daily |
start_date | String(dd/MM/yyyy) | false | e.g. 10/09/2022 Default value: current date. |
end_date | String(dd/MM/yyyy) | false | e.g. 16/09/2022 Default value: current date. |
machine_id | string | false | Filter reports with machine id. |
Response :
{
"status": "1",
"info": "success",
"page_info": {
"record_per_page": "0",
"total_records": "0",
"current_page": "0",
"total_page": "0"
},
"records": [
{
"log_day": "2022-09-10",
"total_value": "10.00",
"card_value": "6.00",
"cash_value": "4.00",
"machine_id": "",
},
... ...
]
}
}
Description:
Request URL:
https://api.circumvend.com.au/api/v1/vmms/reports
Method:
GET
Path Parameters:
Name | Format | Required | Description |
report_type | string | true | report_type = machine_hourly |
log_day | String(dd/MM/yyyy) | false | The date of sales. e.g. 16/09/2022 Default value: current date. |
machine_id | string | false | Filter sales with machine. |
Response :
{
"status": "1",
"info": "success",
"page_info": {
"record_per_page": "0",
"total_records": "0",
"current_page": "0",
"total_page": "0"
},
"records": [
{
"totalValue": "0.00",
"hourlySales": {
"0": "0.00",
"1": "0.00",
"2": "0.00",
"3": "0.00",
"4": "0.00",
"5": "0.00",
"6": "0.00",
"7": "0.00",
"8": "0.00",
"9": "0.0",
"10": "0.00",
"11": "0.00",
"12": "0.00",
"13": "0.00",
"14": "0.00",
"15": "0.00",
"16": "0.00",
"17": "0.00",
"18": "0.00",
"19": "0.00",
"20": "0.00",
"21": "0.00",
"22": "0.00",
"23": "0.00",
"24": "0.00",
}
},
... ...
]
}
}
Description:
Request URL:
https://api.circumvend.com.au/api/v1/vmms/alarms
Method:
GET
Query Parameters:
Name | Format | Required | Description |
Response :
{
"status": "1",
"info": "success",
"page_info": {
"record_per_page": "30",
"total_records": "7",
"current_page": "1",
"total_page": "1"
},
"records": [
{
"alarm_id": "26666",
"location_name": "location",
"machine_id": "12345",
"subject": "Machine 12345 in [location] offline, IMEI:1234567890abcd, normally caused by power off or signal issue. \r\n",
"first_occur_time": "16/07/2022 01:06:09",
"status": "New",
"alarm_type": "Offline",
},
... ...
]
}
}
Description:
Request URL:
https://api.circumvend.com.au/api/v1/vmms/maps?category=all_locations
Method:
GET
Query Parameters:
Name | Format | Required | Description |
Response :
{
"status": "1",
"info": "success",
"page_info": {
"record_per_page": "30",
"total_records": "7",
"current_page": "1",
"total_page": "1"
},
"records": [
{
"latitude": "-37.96199",
"longitude": "145.03839",
"product_empty": "0",
"product_low": "0",
"locationName": "Circumtec Office",
"locationId": "12345",
"product_normal": "5",
"productFull": "100",
"machineCount": "1",
"address": "328 Reserve Rd",
"city": "Cheltenham",
"state": "VIC",
},
... ...
]
}
}
If response status is fail, then, will also return error description.
Response if request not succeed:
{
"status":"0",
"info":"fail" // This field will display 'fail' or error description.
}
GET:
curl --request GET \
--url 'https://api.circumvend.com.au/api/v1/vmms/machines?record_per_page=20' \
--header 'key: api key'
curl --request GET \
--url 'https://api.circumvend.com.au/api/v1/vmms/machines/12345' \
--header 'key: api key'
POST:
curl --request POST \
--url 'https://api.circumvend.com.au/api/v1/vmms/machines' \
--header 'Content-Type: application/json' \
--header 'key: api key' \
--data '{
"serial_no":"testMachine",
"machine_model_id":"1",
"location_id":"2",
"route_id":"3"
}'
curl --request POST \
--url 'https://api.circumvend.com.au/api/v1/vmms/machines/11239' \
--header 'Content-Type: application/json' \
--header 'key: api key' \
--data '{
"machine_model_id":"",
"location_id":"",
"imei":"",
"route_id":""
}'
DELETE:
curl --request DELETE \
--url 'https://api.circumvend.com.au/api/v1/vmms/machines/11239' \
--header 'key: api key'
GET:
$curl = curl_init();
curl_setopt_array($curl, array(
CURLOPT_URL => "https://api.circumvend.com.au/api/v1/vmms/machines?record_per_page=20",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "GET",
CURLOPT_HTTPHEADER => array(
"key: api key"
),
));
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}
$curl = curl_init();
curl_setopt_array($curl, array(
CURLOPT_URL => "https://api.circumvend.com.au/api/v1/vmms/machines/123",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "GET",
CURLOPT_HTTPHEADER => array(
"key: api key"
),
));
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}
POST:
$curl = curl_init();
curl_setopt_array($curl, array(
CURLOPT_URL => "https://api.circumvend.com.au/api/v1/vmms/machines",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "POST",
CURLOPT_POSTFIELDS => "{\n \"serial_no\":\"testMachine\",\n \"machine_model_id\":\"1\",\n \n \"location_id\":\"2\",\n \"route_id\":\"3\"\n}",
CURLOPT_HTTPHEADER => array(
"Content-Type: application/json",
"key: api key"
),
));
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}
$curl = curl_init();
curl_setopt_array($curl, array(
CURLOPT_URL => "https://api.circumvend.com.au/api/v1/vmms/machines/11239",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "POST",
CURLOPT_POSTFIELDS => "{\n \n \"machine_model_id\":\"103\",\n \"location_id\":\"14453\",\n \"imei\":\"861075024559726\",\n \"route_id\":\"2\"\n}",
CURLOPT_HTTPHEADER => array(
"Content-Type: application/json",
"key: api key"
),
));
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}
DELETE:
$curl = curl_init();
curl_setopt_array($curl, array(
CURLOPT_URL => "https://api.circumvend.com.au/api/v1/vmms/machines/123",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "DELETE",
CURLOPT_HTTPHEADER => array(
"key: api key"
),
));
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}
GET:
import requests
url = "https://api.circumvend.com.au/api/v1/vmms/machines"
querystring = {"record_per_page":"20"}
headers = {'key': 'api key'}
response = requests.request("GET", url, headers=headers, params=querystring)
print(response.text)
import requests
url = "https://api.circumvend.com.au/api/v1/vmms/machines/11244"
headers = {'key': 'api key'}
response = requests.request("GET", url, headers=headers)
print(response.text)
POST:
import requests
url = "https://api.circumvend.com.au/api/v1/vmms/machines"
payload = "{\n \"serial_no\":\"testMachine\",\n \"machine_model_id\":\"1\",\n \n \"location_id\":\"2\",\n \"route_id\":\"3\"\n}"
headers = {
'key': "api key",
'Content-Type': "application/json"
}
response = requests.request("POST", url, data=payload, headers=headers)
print(response.text)
import requests
url = "https://api.circumvend.com.au/api/v1/vmms/machines/123"
payload = "{\n \n \"machine_model_id\":\"1\",\n \"location_id\":\"2\",\n \"imei\":\"testImeiNumber\",\n \"route_id\":\"3\"\n}"
headers = {
'key': "api key",
'Content-Type': "application/json"
}
response = requests.request("POST", url, data=payload, headers=headers)
print(response.text)
DELETE:
import requests
url = "https://api.circumvend.com.au/api/v1/vmms/machines/123"
headers = {'key': 'api key'}
response = requests.request("DELETE", url, headers=headers)
print(response.text)
GET:
var settings = {
"async": true,
"crossDomain": true,
"url": "https://api.circumvend.com.au/api/v1/vmms/machines?record_per_page=20",
"method": "GET",
"headers": {
"key": "api key"
}
}
$.ajax(settings).done(function (response) {
console.log(response);
});
var settings = {
"async": true,
"crossDomain": true,
"url": "https://api.circumvend.com.au/api/v1/vmms/machines/123",
"method": "GET",
"headers": {
"key": "api key"
}
}
$.ajax(settings).done(function (response) {
console.log(response);
});
POST:
var settings = {
"async": true,
"crossDomain": true,
"url": "https://api.circumvend.com.au/api/v1/vmms/machines",
"method": "POST",
"headers": {
"key": "api key",
"Content-Type": "application/json"
},
"processData": false,
"data": "{\n \"serial_no\":\"testMachine\",\n \"machine_model_id\":\"1\",\n \n \"location_id\":\"2\",\n \"route_id\":\"3\"\n}"
}
$.ajax(settings).done(function (response) {
console.log(response);
});
var settings = {
"async": true,
"crossDomain": true,
"url": "https://api.circumvend.com.au/api/v1/vmms/machines/123",
"method": "POST",
"headers": {
"key": "api key",
"Content-Type": "application/json"
},
"processData": false,
"data": "{\n \n \"machine_model_id\":\"1\",\n \"location_id\":\"2\",\n \"imei\":\"testImeinumber\",\n \"route_id\":\"3\"\n}"
}
$.ajax(settings).done(function (response) {
console.log(response);
});
DELETE:
var settings = {
"async": true,
"crossDomain": true,
"url": "https://api.circumvend.com.au/api/v1/vmms/machines/123",
"method": "DELETE",
"headers": {
"key": "api key"
}
}
$.ajax(settings).done(function (response) {
console.log(response);
});