Skip to content

Upload list of departments

Request

POST https://api.zoined.com/departments?dryRun=false&separator=%3B&encoding=utf-8

Security
bearerAuth
Query
dryRunbooleanrequired

Only validate the request without storing the data

Example:dryRun=false
separatorstringrequired

Column separator used when loading CSV data

Example:separator=;
encodingstringrequired

Character encoding used in the CSV data (default is utf-8)

Example:encoding=utf-8
Body
Any of:
department_idstringrequired

Department ID

Example:"123"
namestringrequired

Human readable name for the deparment

Example:"Women's clothing"
floor_areanumber

Floor area of deparment in square meters

Example:20
organisation_idstring

ID of attached organisation

Example:"234"
no_customer_seatsnumber

Number of customer seats available

Example:50
custom_dimension1string

Custom Field 1

Example:"Class 3"
custom_dimension2string

Custom Field 2

Example:"New"
custom_dimension3string

Custom Field 3

Example:"Old"
custom_dimension4string

Custom Field 4

Example:"New"
custom_dimension5string

Custom Field 5

Example:"New"
source_systemstring

Identifier of the source system this data is from. Needed when mapping between source system identifiers and master identifiers are used.

Example:"ABCDEF"
curl -i -X POST \
  'https://zapi-api.zoined.com/_mock/departments?dryRun=false&separator=%3B&encoding=utf-8' \
  -H 'Authorization: Bearer <YOUR_token_HERE>' \
  -H 'Content-Type: application/json' \
  -d '{
    "department_id": "123",
    "name": "Women'\''s clothing",
    "floor_area": 20,
    "organisation_id": "234",
    "no_customer_seats": 50,
    "custom_dimension1": "Class 3",
    "custom_dimension2": "New",
    "custom_dimension3": "Old",
    "custom_dimension4": "New",
    "custom_dimension5": "New",
    "source_system": "ABCDEF"
  }'

Responses

Request has been processed successfully.

Headers

  • Content-Type: application/json
Bodyapplication/json
statusstringrequired

Status of the operation OK / Not OK

Example:"OK"
msgstringrequired

Message describing result of operation

Example:"1 entity added"
Response
{ "status": "OK", "msg": "1 entity added" }