Parties

Handle order's parties.


POST/api/v1/orders/{order_id}/parties

Create Party

This endpoint allows the creation of a party.

URL attributes

  • Name
    order_id
    Type
    string required
    Description

    The order id.

Data attributes

  • Name
    name
    Type
    string required
    Description

    The order party's name.

  • Name
    role
    Type
    string required
    Description

    The order party's role.

  • Name
    poc
    Type
    boolean required
    Description

    If the party is a poc(point of contact) or not.

  • Name
    emails
    Type
    array of strings
    Description

    The party emails.

  • Name
    phones
    Type
    array of strings
    Description

    The party phones.

Request

POST
/api/v1/orders/{order_id}/parties
  curl --location --request POST 'https://app.collateralxp.com/api/v1/orders/{order_id}/parties' \
       --header 'X-Api-Key: {api-key}' \
       --header 'Content-Type: application/json' \
       --data-raw '{
           "party": {
             "name": "John Doe",
             "role": "co_borrower",
             "poc": false,
             "emails": [
               "john.doe@email.com"
             ],
             "phones": [
               "555-123-1234"
             ]
           }
         }'

Response

  {
    "id": "a9ce096d-448d-4b56-b378-d2704620598b",
    "email": "john.doe@email.com",
    "emails": [
      "john.doe@email.com"
    ],
    "name": "John Doe",
    "phone": "555-123-1234",
    "phones": [
      "555-123-1234"
    ],
    "poc": false,
    "role": "co_borrower"
  }

PUT/api/v1/orders/{order_id}/parties/{party_id)/toggle_poc

Toggle Party POC

This endpoint allows to toggle the party POC.

URL attributes

  • Name
    order_id
    Type
    string required
    Description

    The order id.

  • Name
    party_id
    Type
    string required
    Description

    The order's party id.

Data attributes

  • Name
    poc
    Type
    boolean required
    Description

    The party POC status.

Request

PUT
/api/v1/orders/{order_id}/parties/{party_id)/toggle_poc
curl --location --request POST 'https://app.collateralxp.com/api/v1/orders/{order_id}/parties/{party_id)/toggle_poc' \
  --header 'X-API-KEY: {api_key}' \
  -d 'poc=true'

Response

{
  "success": true
}