Introduction Last updated: 04 March 2025

The Augmigo API is organized around REST. Our API has predictable resource-oriented URLs, accepts form-encoded or JSON request bodies, and returns JSON-encoded responses, with standard HTTP response codes.

Authentication

The Augmigo API uses Account Id, API key and basic authentication to authenticate requests. You can view and manage your Account Id and API key in the Settings>Integration.

Please keep Account Id, and API Key secure! Do not share your Account Id, and API key in publicly accessible areas such as GitHub, client-side code, and so forth.

All API requests must be made over HTTPS. Calls made over plain HTTP will fail. API requests without basic authentication token will also fail.

After successful authentication, a permission check decides if the user is allowed to perform the requested action. This check uses the existing permissions.

Authentication REST API:
		
	POST 	/api/v1/merchant/auth
	
			
Require Header:
X-ACCT-Id Account Id, Get it from Account > Integration
X-API-KEY API Key, Get it from Account > Integration
X-OUTLET-KEY Granted outlet key. Get it from Account > Outlet
Authorization Basic [Base64 encoded(username:password)]

In order to create Basic Authentication token.

Then username and password is separated by colon. Which is [username]:[password]. Then base 64 encode the "[username]:[password]".

The value of http header Authorization will be "Basic [Basic Authentication token]"

Example of REST API call to authenticate:
		
	curl -X POST \
	--header "X-ACCT-ID: [Account Id]" \ 
	--header "X-API-KEY:[Application Key]" \
	--header "Authorization: Basic [Basic Authentication token]" https://api.augmigo.com//api/v1/auth
		
		
Response after success authenticated:
		
{
    "x-auth-token": [autenticated token],
    "expires_in_seconds": [authenticated token expires in seconds],
    "username": [username],
    "name": [Name of user],
    "outlet_name": [Outlet name],
    "granted_access": [Granted Access]
}		
		
		
Response details:
auth_token Authenticated token, which is required for next APIs call
expires_in_second Length of life in second for authenticated token
granted_access List of granted access.

Manage Customer

The API require auth_token and outlet_key in http header to manage customer details.

outlet_key is used to determine customer is registered from which outlet

Manage Customer REST API:
		
	POST 	/api/v1/customers/register	
	GET 	/api/v1/customers/reference-code/[reference-code]
	PUT 	/api/v1/customers/reference-code/[reference-code]
	DELETE 	/api/v1/customers/reference-code/[reference-code]
	
			
Require Header:
X-AUTH-TOKEN Authenticated token
X-OUTLET-KEY Granted outlet key

Create Customer

Register a new customer account.

		
	POST 	/api/v1/customers/register

		
Customer Fields in HTTP body:
Field name Description Remark
name Full name of customer Mandatory
email Email of customer Either mobile phone or email is required
birth_date Customer date of birth. Format dd/mm/yyyy. E.g. 28/02/1990 Optional
gender Customer gender. Male - m, Female - f Optional
mobile_phone Mobile Phone of customer. Must international format e.g. +6012 345 6789 Either mobile phone or email is required
merchant_reference_code Merchant existing program member card no for reference purpose. Optional
password Customer signin password. Password must be md5 hashed. Mandatory
Example of request:
	
	curl -X POST -H "Content-Type: application/json" \
	-H "x-auth-token:[auth_token]" \
	-H "x-outlet-key:[outlet_key]" \
  	-d '{"name":"Customer Test 1","gender": "m","birth_date":"06/10/1961","email":"custtest1@email.com","mobile_phone":"+60123451234","password": "e10adc3949ba59abbe56e057f20f883e"}' \
	--url https://api.augmigo.com//api/v1/customers/register
		
Response:
Type Description Remark
Success Return created customer details with http code 200 Reference code is required for read, update and delete API call.
Failed
Missing customer data Customer data is required in json format in http body
Email or mobile phone must be provided Either email or mobile phone is required
Email have been taken If email have been used by other customer creation
Mobile phone have been taken If mobile phone have been used by other customer creation
Response Fields:
Field name Description Remark
name Full name of customer
email Email of customer
mobile_phone Mobile Phone of customer. International format e.g. +6012 345 6789
birth_date Customer date of birth. Format dd-mm-yyyy. E.g. 28-02-1990
gender Customer gender. Male - m, Female - f
reference_code Customer reference code 16 digits
merchant_reference_code Merchant existing program member card no for reference purpose.
is_email_verified Boolean value to determine whether the email is verified
is_mobile_phone_verified Boolean value to determine whether the mobile phone is verified
registered_datetime Customer registered datetime. Format dd-mm-yyyy HH:MM:SS. e.g. 09-04-2025 12:09:22
Example of response:

Success response with HTTP code 200

		
		
	{
		""birth_date": [birth date in format dd-mm-yyyy],
		"customer_key": [customer key],
		"email": [registered email],
		"mobile_phone": [registered mobile phone],
		"gender": [gender],
		"is_email_verified": [bool value to determine email is verified],
		"is_mobile_phone_verified": [bool value to determine mobile phone is verified],
		"merchant_reference_code": [merchant reference code],
		"name": [Customer name],
		"reference_code": [customer account reference code],
		"registered_datetime": [registered date time in format dd-mm-yyyy HH:MM:SS],
	}
		
		
		

Failure response with HTTP code 500

			
		
	{
		"msg": ["Email or mobile phone must be provided"]
	}
		
		
		

Failure response with HTTP code 500

		
		
	{
		"msg": ["Email have been taken"]
	}

		
		

Read Customer

Retrieve customer account details.

		
	GET 	/api/v1/customers/reference-code/[reference-code]

		
Example of request:
	
	curl -X GET -H "Content-Type: application/json" \
	-H "x-acct-id:[account id]" \
	-H "x-auth-token:[auth_token]" \
	--url https://api.augmigo.com//api/v1/customers/reference-code/[reference-code]
		
Customer Fields:
Field name Description Remark
name Full name of customer Mandatory
email Email of customer Either mobile phone or email is required
birth_date Customer date of birth. Format dd/mm/yyyy. E.g. 28/02/1990 Optional
gender Customer gender. Male - m, Female - f Optional
mobile_phone Mobile Phone of customer. Must international format e.g. +6012 345 6789 Either mobile phone or email is required
merchant_reference_code Merchant existing program member card no for reference purpose. Optional
Response:
Type Description Remark
Success Return customer account details with http code 200 Refer to customer field for details.
Failed
Return with http 400
Example of response:
		
		
	{
		""birth_date": [birth date in format dd-mm-yyyy],
		"customer_key": [customer key],
		"email": [registered email],
		"mobile_phone": [registered mobile phone],
		"gender": [gender],
		"is_email_verified": [bool value to determine email is verified],
		"is_mobile_phone_verified": [bool value to determine mobile phone is verified],
		"merchant_reference_code": [merchant reference code],
		"name": [Customer name],
		"reference_code": [customer account reference code],
		"registered_datetime": [registered date time in format dd-mm-yyyy HH:MM:SS],
	}
		
		
		

Update Customer

Update customer account details.

		
	PUT		/api/v1/customers/reference-code/[reference-code]

		
Customer Fields in HTTP body:
Field name Description Remark
name Full name of customer Mandatory
email Email of customer Either mobile phone or email is required
birth_date Customer date of birth. Format dd-mm-yyyy. E.g. 28-02-1990 Optional
gender Customer gender. Male - m, Female - f Optional
mobile_phone Mobile Phone of customer. Must international format e.g. +6012 345 6789 Either mobile phone or email is required
merchant_reference_code Merchant existing program member card no for reference purpose. Optional
password Customer signin password. Password must be md5 hashed. Mandatory
Example of request:
	
	curl -X PUT -H "Content-Type: application/json" \
	-H "x-auth-token:[auth_token]" \
	-d '{"name":"Customer Test 1","gender": "m","birth_date":"06/10/1961","email":"custtest1@email.com","mobile_phone":"+60123451234","password": "e10adc3949ba59abbe56e057f20f883e"}' \
	--url https://api.augmigo.com//api/v1/customers/reference-code/[reference-code]
		
Response:
Type Description Remark
Success Return HTTP code 200 Reference code is required for read, update and delete API call.
Failed
Missing customer data Customer data is required in json format in http body
Email or mobile phone must be provided Either email or mobile phone is required
Email have been taken If email have been used by other customer creation
Mobile phone have been taken If mobile phone have been used by other customer creation
Example of response:

Success response in empty content with HTTP code 200

Failure response with HTTP code 500

		
		
	{
		'msg': ['Email or mobile phone must be provided']
	}
		
		
		

Failure response with HTTP code 500

		
		
	{
		'msg': ['Email have been taken']
	}

		
		

Delete Customer

Delete a customer account.

		
	DELETE 	/api/v1/customers/reference-code/[reference-code]

		
Example of request:
	
	curl -X DELETE -H "Content-Type: application/json" \
	-H "x-auth-token:[auth_token]" \
	--url https://api.augmigo.com//api/v1/customers/reference-code/[reference-code]
		
Response:
Type Description Remark
Success Return with http code 204
Failed
Return with http 400

Reward

Give and read reward for customer REST API

			
	GET 	/api/v1/customers/reward/reference-code/[reference-code]
	POST 	/api/v1/customers/reward/reference-code/[reference-code]/give
	
	
			
Require Header:
X-AUTH-TOKEN Authenticated token
X-OUTLET-KEY Transact outlet key

Give Reward

Submit transaction to earn reward based on transaction data. Customer reference_code is required for the API call. The transaction data is JSON format in request body.

		
	POST 	/api/v1/reward/reference-code/[reference-code]/give

		
Give Reward Transaction Fields in HTTP body:
Field name Description Remark
sales_amount Sales amount in currency of transaction. E.g. $12.00 Mandatory
tax_amount Tax amount in currency of transaction. E.g. $0.72 which is 6% of $12.00. Total sales amount to give reward should be sales_amount - tax_amount Optional
transact_datetime

Transaction datetime. If internet connection is not available, then the transaction record have to keep in local and call API when internet connection is available. Thus, the transaction datetime is important in such condition.

Note: The transaction datetime format is dd-mm-yyyy HH:MM:SS. E.g. 15-01-2026 20:07:06

Optional
remarks Remarks of transaction. Maximum 300 characters. Optional
invoice_id Transaction invocie id. Optional
invoice_details

Invoice details including purchased items in JSON format. Certain reward will be given if purchased certain product or service.

Format:

	{					
	"purchased_items": 	[
		{
			"SKU" : "SKU_1",
			"count" : 1,
			"subtotal_sales_amt" : xxxxx,
			"subtotal_tax_amt" : xxxxx
		},
		{
			"SKU" : "SKU_2",
			"count" : 3,
			"subtotal_sales_amt" : xxxxx,
			"subtotal_tax_amt" : xxxxx
		},
				]
	"pax_acount": 1
	}
						

Field name Description
SKU Product or service SKU
subtotal_sales_amt Subtotal sales amount in currency
subtotal_tax_amt Subtotal tax amount in currency
count Count of purchased item
Optional
Example of request:
	
	curl -X POST -H "Content-Type: application/json" \
	-H "x-auth-token:[auth_token]" \
	-H "x-outlet-key:[outlet_key]" \
  	-d '{"sales_amount":100.00,"invoice_id": "XXXXXXXX","tax_amount": 6.0,"invoice_details":{"purchased_items": [{"SKU" : "SKU_1","count" : 1,"subtotal_sales_amt" : 100.00,"subtotal_tax_amt" : 6.0}],"pax_count":1}}' \
	--url https://api.augmigo.com//api/v1/reward/reference-code/[reference-code]/give
		
Response:
Type Description Remark
Success Return transaction id, entitled reward summary and entitled voucher summary with http code 200
Field name Description
entitled_reward_summary

Customer entitled reward summary. Reward type can be:

  • point - Reward point
  • stamp - Stamp chop
entitled_voucher_summary

Customer entitled voucher summary, Summary show list of entitled voucher with voucher label, amount, image url, effective date and expiry date.

transaction_id Transaction id for reference purpose.
Transaction Id is required for read transaction API call.
Failed Return error message with http code 400
Example of response:

Success response with HTTP code 200

		
		
	{
	  "entitled_reward_summary": {
		    "point": {
		      "amount": 188.0, 
		      "latest_expiry_date": "[expiry date in dd-mm-yyyy format]"
		    }, 
		    "stamp": {
		      "amount": 1.0, 
		      "latest_expiry_date": "[expiry date in dd-mm-yyyy format]"
		    }
	  }, 
	  "entitled_voucher_summary":[
				{
				"voucher_program_key": [Vouche program key],
				"amount": 1,
				"effective_date"	: "[effective date in dd-mm-yyyy format]",
				"expiry_date"		: "[expiry date in dd-mm-yyyy format]",
				"image_url"			: "[voucher image url]",
				"label"				: "XXXXXXXX XXXX"
				}
			], 
	  "transaction_id": "XXXXXXXXXXXXXXX"
	}
		
		
		

Failure response with HTTP code 500

		
		{
			"msg":[
				"Sales Amount is required"
				]
		}
		
		

Read Reward

Read reward summary to show customers entitled reward such as Point, Stamp, Prepaid Credit and etc.

		
	GET 	/api/v1/reward/reference-code/[reference-code]

		
Example of request:
	
	curl -X GET 
	-H "x-auth-token:[auth_token]" \
	--url https://api.augmigo.com//api/v1/reward/reference-code/[reference-code]
	
		
Response:
Type Description Remark
Success

Return reward summary with http code 200

Field name Description
entitled_reward_summary

Customer entitled reward summary. Reward type can be:

  • point - Reward point
  • stamp - Stamp chop
  • prepaid - Prepaid amount
  • voucher - Voucher type

    Field name Description
    label Label of voucher
    image_url Image url of voucher
    effective_date Effective date in format dd-mm-yyyy
    expiry_date Expiry date in format dd-mm-yyyy
    redeem_code Voucher code to redeem reward
    voucher_program_key Voucher program key. It can be used as grouping of same voucher type.
Failed Return error message with http code 400
Example of response:

Success response with http code 200

		
		
{
    "entitled_reward_summary": {
        "point": 4254.0,
        "prepaid": 668.8,
        "stamp": 23.0,
        "vouchers": [
            {
                "effective_date": [effective date in format dd-mm-yyyy],
                "expiry_date": [expiry date in format dd-mm-yyyy],
                "image_url": [voucher image url],
                "label": "10% Discount",
                "redeem_code": "vQbduaCKGxDe",
                "voucher_program_key": [voucher program key]
            },
            {
                "effective_date": [effective date in format dd-mm-yyyy],
                "expiry_date": [expiry date in format dd-mm-yyyy],
                "image_url": [voucher image url],
                "label": "RM10",
                "redeem_code": "AWo1T6MxkyGa",
                "voucher_program_key": [voucher program key]
            },
            {
                "effective_date": [effective date in format dd-mm-yyyy],
                "expiry_date": [expiry date in format dd-mm-yyyy],
                "image_url": [voucher image url],
                "label": "RM25",
                "redeem_code": "UaxhedSP9ms8",
                "voucher_program_key": [voucher program key]
            },
		]
}		
		
		

Voucher

Read and redeem voucher REST API

			
	GET 	/api/v1/vouchers/redeem-code/[redeem code]
	POST 	/api/v1/vouchers/redeem	
			
Require Header:
X-AUTH-TOKEN Authenticated token
X-OUTLET-KEY Transact outlet key

Read Voucher

Read customer entitled voucher details

		
	GET 	/api/v1/vouchers/redeem-code/[redeem code]

		
Example of request:
	
	curl -X GET 
	-H "x-auth-token:[auth_token]" \
	--url https://api.augmigo.com//api/v1/vouchers/[voucher redeem code]
	
		
Response:
Type Description Remark
Success Return voucher details with http code 200
Field name Description
label Voucher label
desc Voucher Description
terms_and_conditions Voucher terms and conditions for display purpose.
image_url Voucher image url
redeem_code Voucher redeem code
is_redeemed Indicator to determine whether voucher have been redeemed. true if voucher have been redeemed
effective_date Date when voucher eligible start to redeem. Date format in dd-mm-yyyy
expiry_date Date when voucher stop to redeem. Date format in dd-mm-yyyy
configuration

Voucher configuration in JSON format, which is used for 3rd party integration use purpose

Example Point of Sales system integration, voucher configuration can be used to determine cash rebate, free product or service.

											
											
	{
	      "cash": 10, 
	      "currency_code": "usd", 
	      "label": "$10 Cash Voucher"
	}											
											
											
Failed Return error message with http code 400
Example of response:
		
		
	{
	  "voucher_details": {
	    "configuration": {
	      "cash": 10, 
	      "currency_code": "usd", 
	      "label": "$10 Cash Voucher"
	    }, 
	    "desc": "Allow to rebate $10 in single receipt", 
	    "effective_date": "XX-XX-XXXX", 
	    "expiry_date": "XX-XX-XXXX", 
	    "image_url": "https://www.xxxx.xxxx", 
	    "label": "$ 10 Cash Voucher", 
	    "redeem_code": "XXXXXXXXX", 
	    "terms_and_conditions": "Rebate $ 10 in single receipt"
	  }
	}
		
		
		

Redeem Voucher

Redeem customer entitled voucher with customer reference_code. The redemption data is JSON format in HTTP request body.

		
	POST 	/api/v1/vouchers/redeem

		
Redeem Voucher Fields in HTTP body:
Field name Description Remark
redeem_code Voucher redeem code in array list. E.g. ["xxxxxxxx", "xxxxxxxxx", "xxxxxxxxxxx"] Mandatory
redeem_datetime

Redeem voucher datetime. If internet connection is not available, then the redemption record have to keep in local and call API when internet connection is available. Thus, the redeem datetime is important in such condition.

Note: The redeem datetime format is dd-mm-yyyy HH:MM:SS. E.g. 15-01-2026 20:07:06

Optional
remarks Remarks of transaction. Maximum 300 characters. Optional
invoice_id Redeem invocie id. Optional
Example of request:
	
	curl -X GET 
	-H "x-auth-token:[auth_token]" \
	-H "x-outlet-key:[outlet_key]" \
	-d '{"redeem_code":['xxxxxx','xxxxxx'],"invoice_id": "XXXXXXXX","remarks": "xxxxxxx"}"' \
	--url https://api.augmigo.com//api/v1/vouchers/[customer reference code]
	
		
Response:
Type Description Remark
Success Return transaction ID with http code 200
Failed Return error message with http code 400
Example of response:
		
		
	{
		"transaction_id": "xxxxxxxxxxxx"
	}
		
		
		

Manage Membership

The API require auth_token and outlet_key in http header to manage membership.

outlet_key is used to determine membership is managed from which outlet

Manage Membership REST API:
		
	POST 	/api/v1/customer-membership/customer/reference-code/[reference-code]/assign-membership	
	GET 	/api/v1/customer-membership/customer/reference-code/[reference-code]
	DELETE 	/api/v1/customer-membership/customer/reference-code/[reference-code]/remove-membership
	
			
Require Header:
X-AUTH-TOKEN Authenticated token
X-OUTLET-KEY Granted outlet key

Read Customer Membership Details

Read customer membership details.

		
	GET 	/api/v1/customer-membership/customer/reference-code/[reference-code]

		
Example of request:
	
	curl -X GET -H "Content-Type: application/json" \
	-H "x-acct-id:[account id]" \
	-H "x-auth-token:[auth_token]" \
	--url https://api.augmigo.com//api/v1/customer-membership/customer/reference-code/[reference-code]
		
Response:
Type Description Remark
Success Return list of customer membership details Refer to customer membership response for details.
Failed
Return with http 400
Response Fields:
Type Description Remark
desc Description of membership program
label Label of membership program card
entitled_date Entitled date In format dd-mm-yyyy
expiry_date Expiry date In format dd-mm-yyyy
terms_and_conditions Terms and conditions of the membership program
Example of response:

Success reponse with HTTP code 200

		
		
	[
		{
		"desc": [Description],
		"entitled_date": [entitled date in format dd-mm-yyyy],
		"expiry_date": [expiry date in format dd-mm-yyyy],
		"label": [Membership card label],
		"terms_and_conditions": [Terms and conditions]
		}
	]
		
		
		

Assign Membership

Assign membership to customer.

		
	POST 	/api/v1/customer-membership/customer/reference-code/[reference-code]/assign-membership

		
Customer Fields in HTTP body:
Field name Description Remark
membership_key Key of membership program Mandatory
number_of_year Number of year Optional
Example of request:
	
	curl -X POST -H "Content-Type: application/json" \
	-H "x-auth-token:[auth_token]" \
	-H "x-outlet-key:[outlet_key]" \
  	-d '{"membership_key":[membership key]}' \
	--url https://api.augmigo.com//api/v1/customer-membership/customer/reference-code/[reference-code]/assign-membership
		
Response:
Type Description Remark
Success Return http code 200
Failed
Missing membership program key, with http code 500 Merchant membership program key is required in json format in http body
The customer membership has already been assigned, with http code 500 The membership have been assigned
Example of response:

Success response with HTTP code 200

		
		
		

Failure response with HTTP code 500

			
		
	{
		"msg": ["Missing membership program key"]
	}
		
		
		

Failure response with HTTP code 500

		
		
	{
		"msg": ["The customer membership has already been assigned"]
	}