I have faced an issue on the domain registration API integration which is provided by GoDaddy. I have a reseller account on GoDaddy. When i execute the domain registration API with sample data, the api returns an invalid body message with the below mentioned error for the "phone number" field.
Can anyone help me to fix the issue so that i can move further with the API.
The API url to be used for the registration api is as follows:-
https://api.ote-godaddy.com/v1/domains/purchase
The inputted JSON format raw data content for the contact details part is as follows:
"contactAdmin": {
"nameFirst": "Raidel",
"nameMiddle": " ",
"nameLast": "Arooja",
"organization": "US IT Company",
"jobTitle": "Developer",
"email": "raidel.a@usitcompany.com",
"phone": "+1-773-737-4427",
"fax": "",
"addressMailing": {
"address1": "US IT Company",
"address2": "IL,60015,US",
"city": "Illinois",
"state": "IL",
"postalCode": "60015",
"country": "US"
}
}
We have used the valid phone number format for Illinois state in US (+1-773-737-4427). But whenever i execute the API, i got the following error. I have tried different other formats of the phone number which is valid in US. But all the time, the error repeats.
Error data:
{
"code": "INVALID_BODY",
"message": "Request body doesn't fulfill schema, see details in `fields`",
"responseModel": "Error",
"fields": [{
"message": "does not conform to the 'phone' format, based on pattern: /^\\+([0-9]){1,3}\\.([0-9]\\ ?){6,14}$/",
"path": "body.contactAdmin.phone",
"code": "MISMATCH_FORMAT"
}]
}
Issues:-
- Can anyone confirm the exact format for the phone number field which is valid for the domain registration API as soon as possible?
- Confirm one more point - Is the "X-shopper ID" needed for this API is same as customer ID displayed on the reseller account or not?
Ref: https://developer.godaddy.com/doc#!/_v1_domains/purchase/DomainPurchase