Companies

Update company

PUT company (admin)

Endpoint

PUT /api/v1/companies/:id

Parameters

Name Description
company[name] Company name
company[address] Company address
company[license_number] Company license number
company[vat_number] Company vat number
company[invoice_email] Company invoice email
company[billing_phone_number] Company billing phone number
company[billing_full_name] Company billing full name
company[billing_address] Company billing address
company[due_days] Company due days
company[commission] Company commission
company[country] Company country
company[currency] Company currency

Request

Route

PUT /api/v1/companies/32

Headers

Accept: application/json
Content-Type: application/json
Authorization: Bearer eyJhbGciOiJIUzI1NiJ9.eyJzdWIiOiIxMzMiLCJzY3AiOiJ1c2VyIiwiYXVkIjpudWxsLCJpYXQiOjE3NjA5NTA0MzUsImV4cCI6MTc2MzU0MjQzNSwianRpIjoiYTI0OTRjZGItNGJhNC00MDBmLTkyYWQtYTAwODU2OTM1ZjZjIn0.CTg0qgcz7VNx_rrrvMcLHFV0W0e_NySKnE7d5ySKEc4
Host: example.org
Cookie: 

Body

{
  "company": {
    "name": "Legros-Roberts",
    "address": "7792 Ashlea Knolls, North Ngan, IA CB4 8LJ",
    "license_number": "68535734050",
    "invoice_email": "keenan.macgyver@morar.example",
    "vat_number": "24879038140",
    "billing_phone_number": "+4407327148568",
    "billing_full_name": "Amado Hills DC",
    "billing_address": "Suite 800 33045 Gilberto Creek, Port Willowbury, OH WF6 7DF",
    "due_days": 20,
    "commission": 5
  }
}

Response

Simulated Response

Status

200

Headers

x-frame-options: SAMEORIGIN
x-xss-protection: 0
x-content-type-options: nosniff
x-permitted-cross-domain-policies: none
referrer-policy: strict-origin-when-cross-origin
content-type: application/json; charset=utf-8
vary: Accept, Origin
etag: W/"c9fe84b198f55f2e6982fbbd58ae41b9"
cache-control: max-age=0, private, must-revalidate
x-request-id: ce4ea3aa-0668-4dc1-a604-61baa3e45144
x-runtime: 0.012814
content-length: 653

Body

{
  "company": {
    "id": 32,
    "address": "7792 Ashlea Knolls, North Ngan, IA CB4 8LJ",
    "available_currencies": [
      "GBP",
      "EUR"
    ],
    "billing_address": "Suite 800 33045 Gilberto Creek, Port Willowbury, OH WF6 7DF",
    "billing_full_name": "Amado Hills DC",
    "billing_phone_number": "+4407327148568",
    "commission": "5.0",
    "country": "GBR",
    "currency": "GBP",
    "due_days": 20,
    "invoice_email": "keenan.macgyver@morar.example",
    "license_number": "68535734050",
    "minimum_wage": {
      "21+": {
        "min_wage": 12.21,
        "min_umbrella_rate": 16.13,
        "min_charge_rate": 17.92
      },
      "18-20": {
        "min_wage": 10.0,
        "min_umbrella_rate": 12.55,
        "min_charge_rate": 13.58
      }
    },
    "name": "Legros-Roberts",
    "state": "verified",
    "vat_number": "24879038140"
  }
}