Bulk Usergroup Addresses
POST/usergroups/:lookupKey/:lookupValue/addresses/bulk
Use this endpoint to create multiple usergroup addresses with a single API request. If an address with the code provided is found, it will be updated, otherwise a new address will be created. If the code is not provided, a new address will be created. When a new address is successfully created, the response will include the address id
.
Fields
Name | Required |
---|---|
type | yes |
code | yes |
firstName | no |
middleName | no |
lastName | no |
gender | no Default is U |
street | yes |
number | no |
numberExtension | no |
postalCode | no |
city | yes |
country | yes |
region | no |
icp | no Default is N |
phone | no |
mobile | no |
email | no |
company | no |
url | no |
isDefault | no Default is N |
notes | no |
Request
Path Parameters
Lookup key. Read more about usergroup lookup keys
The value of the key (id or sourceId)
- application/json
Body
Array [
]
addresses
object[]
Responses
- 201
- 400
- 404
Bulk Usergroup Addresses - 201
Response Headers
Alt-Svc
string
Via
string
alt-svc
string
content-length
string
date
string
return-format
string
server
string
x-request-id
string
- application/json
- Schema
- Example (from schema)
- Bulk Usergroup Addresses - 201
Schema
data
object
{
"data": {
"city": "Arnhem",
"code": "11234",
"company": "Propel",
"country": "NL",
"email": "miles@propel.us",
"firstName": "Miles",
"icp": "N",
"id": 81908,
"isDefault": "Y",
"lastName": "McCoy",
"middleName": "",
"mobile": "0038975648",
"notes": "Address notes",
"number": "34",
"numberExtension": "A",
"phone": "0032445888",
"postalCode": "6822 DE",
"region": "",
"street": "Noordpad",
"type": "delivery",
"url": "www.propel.us"
},
"messages": [
"Address created"
],
"total": 1
}
{
"data": {
"city": "Arnhem",
"code": "11234",
"company": "Propel",
"country": "NL",
"email": "miles@propel.us",
"firstName": "Miles",
"icp": "N",
"id": 81908,
"isDefault": "Y",
"lastName": "McCoy",
"middleName": "",
"mobile": "0038975648",
"notes": "Address notes",
"number": "34",
"numberExtension": "A",
"phone": "0032445888",
"postalCode": "6822 DE",
"region": "",
"street": "Noordpad",
"type": "delivery",
"url": "www.propel.us"
},
"messages": [
"Address created"
],
"total": 1
}
Bulk Usergroup Addresses - 400
Response Headers
Alt-Svc
string
Via
string
alt-svc
string
content-length
string
date
string
return-format
string
server
string
x-request-id
string
- application/json
- Schema
- Example (from schema)
- Bulk Usergroup Addresses - 400
Schema
error
object
{
"error": {
"code": 10007,
"messages": [
"#/isDefault: U is not a valid enum value"
],
"moreInfo": "https://www.propel.us/docs/errors/10007",
"status": 400,
"type": "SchemaValidationException"
}
}
{
"error": {
"code": 10007,
"messages": [
"#/isDefault: U is not a valid enum value"
],
"moreInfo": "https://www.propel.us/docs/errors/10007",
"status": 400,
"type": "SchemaValidationException"
}
}
Bulk Usergroup Addresses - 404
Response Headers
Alt-Svc
string
Via
string
alt-svc
string
content-length
string
date
string
return-format
string
server
string
x-request-id
string
- application/json
- Schema
- Example (from schema)
- Bulk Usergroup Addresses - 404
Schema
error
object
{
"error": {
"code": 70007,
"messages": [
"Parent resource [User] with id [147601] not found"
],
"moreInfo": "https://www.propel.us/docs/errors/70007",
"status": 404,
"type": "ParentUserNotFound"
}
}
{
"error": {
"code": 70007,
"messages": [
"Parent resource [User] with id [147601] not found"
],
"moreInfo": "https://www.propel.us/docs/errors/70007",
"status": 404,
"type": "ParentUserNotFound"
}
}