Contact (Create)

Creates a new Contact.

Authentication

Every request needs both of the following:

  • An authorized UserID, passed in to the request body — this is the user's cieTrade.net email.
  • A Bearer Token in the Authorization header of your tool or code call. The token is found under Settings → Integration → Api Token.

The user must have Can Access cieTrade API checked under Settings → Users & Roles, and must have an email address on their user record — the create and update endpoints record that user against every change they make.

Request Example

{
  "UserID": "example@email.net",
  "FirstName": "Bob",
  "LastName": "Stone",
  "CompanyName": "3P GLOBAL RESOURCES LLC",
  "Location": "Main Office",
  "MobilePhone": "555-201-4410",
  "WorkPhone": "555-201-4400",
  "JobTitle": "Logistics Manager",
  "Email": "bob.stone@example.com",
  "Notes": "Prefers to be contacted by email.",
  "Roles": ["Collections", "Billing"]
}

Body Parameters

Parameter Description Required
UserID cieTrade.NET User Email. Used for Authentication and Logging. REQUIRED
FirstName Contact's first name. REQUIRED
LastName Contact's last name. OPTIONAL
CompanyName Company the contact belongs to. Must match a Counterparty in cieTrade. If omitted, the contact is created without a company. OPTIONAL
Location Location of the contact. Must match a Location that exists under the Counterparty given in CompanyName. Ignored if CompanyName is not supplied. OPTIONAL
MobilePhone Mobile phone number. OPTIONAL
WorkPhone Work phone number. OPTIONAL
JobTitle Contact's job title. OPTIONAL
Email Contact's email address. OPTIONAL
Notes Notes about the contact. Up to 200 characters. OPTIONAL
Roles List of roles to assign to the contact (e.g. ["Collections", "Billing"]). See Roles section below. OPTIONAL

Roles

Roles is sent as a list of role names. Each role must match a Contact Role in cieTrade. If any role in the list is not valid, the request is rejected and the contact is not created.

Response Example

On Success [HTTP 201]:

{
    "Msg": "Successfully Created Contact Bob Stone"
}

On Error [HTTP 500/HTTP 401/HTTP 400]:

{
    "ErrMsg": "Error: Unable to find Company 3P GLOBAL RESOURCES LLC in cieTrade."
}
Did this answer your question? Thanks for the feedback There was a problem submitting your feedback. Please try again later.