PUT
/
v1
/
organizations
/
{organizationId}
/
addresses
/
{addressId}
curl --request PUT \
  --url https://live.copilot.fabric.inc/data-customer/v1/organizations/{organizationId}/addresses/{addressId} \
  --header 'Authorization: Bearer <token>' \
  --header 'Content-Type: application/json' \
  --header 'x-site-context: <x-site-context>' \
  --data '{
  "globalAddressId": 1234,
  "type": "M",
  "addressLine1": "street 1",
  "addressLine2": "street 2",
  "addressLine3": "street 3",
  "addressLine4": "street 4",
  "county": "San Diego",
  "city": "Boston",
  "state": "Texas",
  "zipCode": 12345,
  "postalCode": "ABC-123",
  "country": "USA",
  "latitude": 38.8951,
  "longitude": -77.0364,
  "isDefault": false,
  "groupId": "61604a30fdfacd0009816e46",
  "additionalAttributes": {}
}'
{
  "_id": "61604a30fdfacd0009816e44",
  "globalAddressId": 1234,
  "type": "M",
  "addressLine1": "street 1",
  "addressLine2": "street 2",
  "addressLine3": "street 3",
  "addressLine4": "street 4",
  "county": "San Diego",
  "city": "Boston",
  "state": "Texas",
  "zipCode": 12345,
  "postalCode": "ABC-123",
  "country": "USA",
  "latitude": 38.8951,
  "longitude": -77.0364,
  "groupId": "61604a30fdfacd0009816e46",
  "additionalAttributes": {},
  "isDeleted": false,
  "isDefault": false,
  "createdAt": "2021-08-30T23:20:42.822Z",
  "updatedAt": "2021-08-30T23:20:42.822Z"
}

Authorizations

Authorization
string
header
required

Bearer authentication header of the form Bearer <token>, where <token> is your auth token.

Headers

x-site-context
string
required

The x-site-context header is a JSON object that contains information about the source you wish to pull from. The mandatory account is the 24 character identifier found in Copilot. The channel (Sales channel ID), stage (environment name), and date attributes can be used to further narrow the scope of your data source.

Example:

"{\"date\": \"2023-01-01T00:00:00.000Z\", \"channel\": 12, \"account\": \"1234abcd5678efgh9ijklmno\",\"stage\":\"production\"}"

Path Parameters

organizationId
string
required

Fabric internal id of the record

Example:

"61a558b1b155125f02be7fb1"

addressId
string
required

Fabric internal id of the record

Example:

"61a558b1b155125f02be7fb2"

Body

application/json
A sample request to update an oraganizations address.
type
enum<string>
required

type of the address. M=Mail, E=Email, P=Postal

Available options:
M,
E,
P
Example:

"M"

globalAddressId
number

global address id

Example:

1234

addressLine1
string

address line 1. If sent it has to contain 1 character or more.

Example:

"street 1"

addressLine2
string

address line 2

Example:

"street 2"

addressLine3
string

address line 3

Example:

"street 3"

addressLine4
string

address line 4

Example:

"street 4"

county
string

county

Example:

"San Diego"

city
string

city

Example:

"Boston"

state
string

state

Example:

"Texas"

zipCode
number

zipCode

Example:

12345

postalCode
string

postalCode

Example:

"ABC-123"

country
string

country

Example:

"USA"

latitude
number

latitude

Example:

38.8951

longitude
number

longitude

Example:

-77.0364

isDefault
boolean

Default Address

Example:

false

groupId
string

Fabric internal id of the group record.

Example:

"61604a30fdfacd0009816e46"

additionalAttributes
object

Contains all additional attributes not captured in the schema.

Response

200
application/json
sample response
_id
string
required

Fabric internal id of the record

Example:

"61604a30fdfacd0009816e44"

type
enum<string>
required

type of the address. M=Mail, E=Email, P=Postal

Available options:
M,
E,
P
Example:

"M"

isDeleted
boolean
required

flag that indicates if the record is deleted

Example:

false

createdAt
string
required

date of creation of the record

Example:

"2021-08-30T23:20:42.822Z"

updatedAt
string
required

laste date of update of the record

Example:

"2021-08-30T23:20:42.822Z"

globalAddressId
number

global address id

Example:

1234

addressLine1
string

address line 1

Example:

"street 1"

addressLine2
string

address line 2

Example:

"street 2"

addressLine3
string

address line 3

Example:

"street 3"

addressLine4
string

address line 4

Example:

"street 4"

county
string

county

Example:

"San Diego"

city
string

city

Example:

"Boston"

state
string

state

Example:

"Texas"

zipCode
number

zipCode

Example:

12345

postalCode
string

postalCode

Example:

"ABC-123"

country
string

country

Example:

"USA"

latitude
number

latitude

Example:

38.8951

longitude
number

longitude

Example:

-77.0364

groupId
string

Fabric internal id of the group record.

Example:

"61604a30fdfacd0009816e46"

additionalAttributes
object

Contains all additional attributes not captured in the schema.

isDefault
boolean

flag that indicates if the record is default

Example:

false