Customers and packages
Customers
Create Wasil customers from your own platform. Each one is a full Wasil customer with a suite, the address they ship their purchases to.
Creating a customer is real: it opens a Wasil account and a US shipping address for that person. Create customers only for real people who asked for it, never for tests. Ask your Wasil contact for a test arrangement.
/v1/customers
write module
| Field | Type | Meaning |
|---|---|---|
name | text, required | The customer's full name, 2 to 120 characters. |
phone | text, required | An Iraqi mobile number. +9647701234567, 9647701234567 and 07701234567 are all accepted and mean the same number. |
email | text | Optional. Must not be in use by another Wasil customer. |
city_id | number, required | The customer's city, from GET /v1/cities. |
address | text | Street address for home delivery, up to 255 characters. |
password | text | Optional, at least 8 characters: lets the customer sign in to the Wasil app with their phone. Without it a random password is set, and the customer sets their own through the app's password reset. |
curl -X POST https://api.wasil-iq.com/v1/customers \
-H "Authorization: Bearer $WASIL_KEY" \
-H "Content-Type: application/json" \
-d '{
"name": "Sara Ahmed",
"phone": "+9647701234567",
"email": "[email protected]",
"city_id": 1,
"address": "Street 40, Ankawa"
}'
HTTP/1.1 201 Created
{
"data": {
"suite": "UM1EX042",
"name": "Sara Ahmed",
"phone": "9647701234567",
"email": "[email protected]",
"city": { "id": 1, "name": "Erbil" },
"address": "Street 40, Ankawa",
"origin": "created",
"myus_status": "processing",
"created_at": "2026-10-03T14:05:00+03:00"
}
}
The suite
The answer's suite is what the customer puts in the shipping address when they buy.
Customers you create get a suite in your own series: UM1, your two-letter partner code, three digits.
See Suites and package ids.
The US address
myus_status follows the opening of the customer's US address, which takes a few seconds after the answer:
processing: being opened. The suite is already final and can be shown to the customer.completed: ready. Thecustomer.myus_readyevent is sent.failed: it could not be opened. The customer exists and every other origin works; Wasil staff retry the US address.pending: not started (linked accounts created long ago may show this).
When the customer already exists
A phone can belong to one customer. If the phone is already one of your customers, you get the suite back and can carry on with it. If it belongs to a Wasil customer who is not yours, you get the same code without a suite; ask Wasil to link that account to you.
HTTP/1.1 409 Conflict
{
"error": {
"code": "customer_exists",
"message": "This phone already belongs to one of your customers.",
"suite": "UM1EX042"
}
}
409 busy means two of your requests tried to create a customer at the same instant; send the request again after a second.
/v1/customers
write module
All your accounts, linked and created, in the order they became yours. Takes page and per_page; answers a list of customer objects with meta.
/v1/customers/{suite}
write module
One customer by suite. A suite that is not yours answers 404.
curl https://api.wasil-iq.com/v1/customers/UM1EX042 \
-H "Authorization: Bearer $WASIL_KEY"
The customer object
| Field | Type | Meaning |
|---|---|---|
suite | text | The customer's suite. The id you use for this customer everywhere in the API. |
name | text | Full name. |
phone | text | Mobile number as Wasil stores it (9647…). |
email | text or null | Email address. |
city | object or null | id and name. |
address | text or null | Street address. |
origin | text | created (by you) or linked (by Wasil). |
myus_status | text | State of the US address, see above. |
created_at | moment | When the customer was created. |