Retrieve a contractor

GET /api/v1/contractors/{contractor_id}

Retrieves the details of an existing contractor. You need only supply the unique contractor identifier that was returned upon contractor creation.

Path parameters

  • contractor string Required

    The ID of the desired contractor (e.g., cn_Ehb3bYa).

Responses

  • 200 application/json

    Returns a contractor object if a valid identifier was provided.

    Hide response attributes Show response attributes object
    • address object
      Hide address attributes Show address attributes
      • country string | null

        2-letter country code.

      • line1 string

        Address line 1 (Street address/PO Box).

      • line2 string | null

        Address line 2 (Apartment/Suite/Unit/Building).

      • locality string

        City/District/Suburb/Town/Village.

      • ZIP or postal code.

      • region string

        2-letter state code.

    • company_name string | null

      The contractor's business name.

    • created integer(int64)

      Time at which the object was created. Measured in seconds since the Unix epoch.

    • Set of key-value pairs that you can attach to the contractor object. Used for storing additional information in a structured format. Individual keys can be unset by posting an empty value to them. Pass an empty value, e.g. {}, to custom_metadata to unset all keys.

    • email string

      The contractor's email address.

    • The contractor's first name.

    • id string
    • The contractor's last name.

    • middle_name string | null

      The contractor's middle name.

    • phone string

      The contractor's phone number.

    • This indicates whether the contractor is paying premium directly with their credit card (i.e., false) or if the contractor has given the platform that's integrating with 1099Policy permission to withhold the premium payment from their wages and pay the premium on the contractor's behalf (i.e., true). Defaults to false.

      Default value is false.

GET /api/v1/contractors/{contractor_id}
curl \
 -X GET https://api.1099policy.com/api/v1/contractors/{contractor_id}
Response examples (200)
{
  "address": {
    "country": "null",
    "line1": "92 Geary St",
    "line2": "null",
    "locality": "San Francisco",
    "postalcode": 94114,
    "region": "CA"
  },
  "company_name": "Acme Co.",
  "created": 1646818364,
  "custom_metadata": {
    "campaign": "Red Bull"
  },
  "email": "parker@gmail.com",
  "first_name": "Joe",
  "id": "cn_Ehb3bYa",
  "last_name": "Parker",
  "middle_name": "null",
  "phone": "415-474-9088",
  "withhold_premium": false
}