Welcome to Codebox documentation!

Here you’ll find handy documentation about our API and products.

Getting Started

only 3 easy steps are needed to get started:

1. Create an Account

If you don’t have an account yet, this is the place to begin. Visit the Storesignup page, where you will have to register using an email address and password.

2. Fill your Store Information

Add more details about your store name, email of store representative, store URL link or
instagram page, product or service category, and commercial registration (CR) number.

3. Start the integration

Integrating with systems can be tricky and not straight forward sometimes, that is why Codebox made it its own mission to connect merchants and customers with simple yet powerful solution.

In this guide we will help you go through the process of linking your platform to Codebox and start accepting displaying your coupons within no time.

1. Create New Coupon:

In creating new coupon, you need to provide us with the following parameters:

https://codeboxads.com/wp-json/wp/v2/coupon/create

access_token: the unique id for your store where it will communicate with code box. This will be provided to you once you are approved in codebox.

title_en: the title of the coupon code that will be displayed to the users who are using the English version of the website

ex, 15% Discount On All Codebox Products

title_ar: the title of the coupon code that will be displayed to the users who are using the Arabic version of the website

ex, خصم ١٥٪ على كافة منتجات كود بوكس

code: the coupon code

ex, Nationalday92

start_date: when the coupon code will be come valid and users can start using it. Start date should be in the following format: DD/MM/YYYY.

ex, 15/09/2022

expiry_date: when the coupon code will be invalid and users won’t be able to use it any more. Expiry date should be in the following format: DD/MM/YYYY.

ex, 20/09/2022

number_usage: how many times the coupon code is allowed to be used.

ex, 100

available_in: in which countries the coupon code is valid.

ex, Saudi, UAE….

2. Edit coupon code

The same variables and functions used in create coupon can be edited herehttps://codeboxads.com/wp-json/wp/v2/coupon/edit

access_token: the unique id for your store where it will communicate with code box. This will be provided to you once you are approved in codebox.

title_en: the title of the coupon code that will be displayed to the users who are using the English version of the website

ex, 15% Discount On All Codebox Products

title_ar: the title of the coupon code that will be displayed to the users who are using the Arabic version of the website

ex, خصم ١٥٪ على كافة منتجات كود بوكس

code: the coupon code

ex, Nationalday92

start_date: when the coupon code will be come valid and users can start using it. Start date should be in the following format: DD/MM/YYYY.

ex, 15/09/2022

expiry_date: when the coupon code will be invalid and users won’t be able to use it any more. Expiry date should be in the following format: DD/MM/YYYY.

ex, 20/09/2022

number_usage: how many times the coupon code is allowed to be used.

ex, 100

available_in: in which countries the coupon code is valid.

ex, Saudi, UAE….

current_code: the previous coupon code.

3. Remove coupon

By removing the coupon, this coupon will not be displayed anymore for the buyers but will be kept in our records for future considerations.https://codeboxads.com/wp-json/wp/v2/coupon/remove

access_token: the unique id for your store where it will communicate with code box code

code: the coupon code

4. Coupon Usage and Analytics:

By sharing the below variable, we will be able to view a clear analytics dashboard regarding store page visits, total coupon added, active coupon, coupons’ usage and much more.https://codeboxads.com/wp-json/wp/v2/coupon/usage

access_token: the unique id for your store where it will communicate with code box. This will be provided to you once you are approved in codebox.

amount: amount of transaction using this coupon code. amount should be numeric.

Date: date of transaction using this coupon code. Date should be in the following format: DD/MM/YYYY.

code: the coupon code

To download the collection file, click here