---
title: "Update an agency"
---

> Documentation Index
> Fetch the complete documentation index at: https://docs.nicer.travel/llms.txt
> Use this file to discover all available pages before exploring further.

# Update an agency

Path: Nicer API › identity

`PUT /identity/company/{companyName}`

URL: `https://api.nicer.travel/identity/company/{companyName}`

Changes the agency's display name and its card: of config, only locale, timezone and the branding's logoUrl, faviconUrl and primaryColor are written, and those three are replaced by what is sent, so one left out is cleared. The rest of the theme, the booking-site switches and the email sending domain are kept: they change through their own routes. Only Nicer staff change status (active or suspended). Publishes the change and answers the agency as it now stands. Agency admins and Nicer staff, for the agency the request acts for only. Errors: 403 ERROR_DO_NOT_HAVE_PERMISSION for a status change by anyone but Nicer staff, 400 ERROR_ITEM_NOT_FOUND for another agency or one there is not.

## Authentication

- `bearerAuth`, http bearer, header `Authorization`, format `JWT`

## Path parameters

- `companyName` (`identity.company.update.path.companyName`; string, required)

## Header parameters

- `x-nicer-company` (`identity.company.update.header.x-nicer-company`; string, optional) — Company context for an agency admin who belongs to several companies. Optional when the caller belongs to one.

## Request body

_Required._

- `config` (`identity.company.update.config`; object, optional)
  - `bookingSite` (`identity.company.update.config.bookingSite`; object, optional)
    - `advisorSites` (`identity.company.update.config.bookingSite.advisorSites`; boolean, optional)
    - `enabled` (`identity.company.update.config.bookingSite.enabled`; boolean, optional)
    - `handle` (`identity.company.update.config.bookingSite.handle`; string, optional)
  - `branding` (`identity.company.update.config.branding`; object, optional)
    - `accentColor` (`identity.company.update.config.branding.accentColor`; string, optional)
      - pattern: `^#[0-9a-fA-F]{6}$`
    - `backgroundColor` (`identity.company.update.config.branding.backgroundColor`; string, optional)
      - pattern: `^#[0-9a-fA-F]{6}$`
    - `bodyFont` (`identity.company.update.config.branding.bodyFont`; string, optional)
      - one of `"Inter"`, `"DM Sans"`, `"Manrope"`, `"Poppins"`, `"Montserrat"`, `"Lato"`, `"Nunito"`, `"Work Sans"`, `"Playfair Display"`, `"Merriweather"`, `"Lora"`, `"Cormorant Garamond"`
    - `borderColor` (`identity.company.update.config.branding.borderColor`; string, optional)
      - pattern: `^#[0-9a-fA-F]{6}$`
    - `contact` (`identity.company.update.config.branding.contact`; object, optional)
      - `email` (`identity.company.update.config.branding.contact.email`; string, optional)
        - format: `email` · maxLength: `254` · pattern: `^(?!\.)(?!.*\.\.)([A-Za-z0-9_'+\-\.]*)[A-Za-z0-9_+-]@([A-Za-z0-9][A-Za-z0-9\-]*\.)+[A-Za-z]{2,}$`
      - `instagram` (`identity.company.update.config.branding.contact.instagram`; string, optional)
        - maxLength: `64`
      - `phone` (`identity.company.update.config.branding.contact.phone`; string, optional)
        - maxLength: `32`
      - `whatsapp` (`identity.company.update.config.branding.contact.whatsapp`; string, optional)
        - maxLength: `32`
    - `faviconUrl` (`identity.company.update.config.branding.faviconUrl`; string, optional)
    - `headingFont` (`identity.company.update.config.branding.headingFont`; string, optional)
      - one of `"Inter"`, `"DM Sans"`, `"Manrope"`, `"Poppins"`, `"Montserrat"`, `"Lato"`, `"Nunito"`, `"Work Sans"`, `"Playfair Display"`, `"Merriweather"`, `"Lora"`, `"Cormorant Garamond"`
    - `hero` (`identity.company.update.config.branding.hero`; object, optional)
      - `imageUrl` (`identity.company.update.config.branding.hero.imageUrl`; string, optional)
        - format: `uri` · maxLength: `2048`
      - `subtitle` (`identity.company.update.config.branding.hero.subtitle`; string, optional)
        - maxLength: `160`
      - `title` (`identity.company.update.config.branding.hero.title`; string, optional)
        - maxLength: `80`
    - `logoDarkUrl` (`identity.company.update.config.branding.logoDarkUrl`; string, optional)
      - format: `uri` · maxLength: `2048`
    - `logoUrl` (`identity.company.update.config.branding.logoUrl`; string, optional)
    - `mode` (`identity.company.update.config.branding.mode`; string, optional)
      - one of `"light"`, `"dark"`, `"system"`
    - `mutedTextColor` (`identity.company.update.config.branding.mutedTextColor`; string, optional)
      - pattern: `^#[0-9a-fA-F]{6}$`
    - `primaryColor` (`identity.company.update.config.branding.primaryColor`; string, optional)
    - `privacyUrl` (`identity.company.update.config.branding.privacyUrl`; string, optional)
      - format: `uri` · maxLength: `2048`
    - `radius` (`identity.company.update.config.branding.radius`; integer, optional)
      - maximum: `24` · minimum: `0`
    - `seo` (`identity.company.update.config.branding.seo`; object, optional)
      - `description` (`identity.company.update.config.branding.seo.description`; string, optional)
        - maxLength: `160`
      - `title` (`identity.company.update.config.branding.seo.title`; string, optional)
        - maxLength: `60`
    - `surfaceColor` (`identity.company.update.config.branding.surfaceColor`; string, optional)
      - pattern: `^#[0-9a-fA-F]{6}$`
    - `textColor` (`identity.company.update.config.branding.textColor`; string, optional)
      - pattern: `^#[0-9a-fA-F]{6}$`
  - `emailSending` (`identity.company.update.config.emailSending`; object, optional)
    - `checkedAt` (`identity.company.update.config.emailSending.checkedAt`; string, required)
    - `dkimTokens` (`identity.company.update.config.emailSending.dkimTokens`; array of string, required)
      - minLength: `1`
    - `domain` (`identity.company.update.config.emailSending.domain`; string, required)
      - maxLength: `253` · minLength: `1`
    - `status` (`identity.company.update.config.emailSending.status`; string, required)
      - one of `"FAILED"`, `"PENDING"`, `"VERIFIED"`
    - `tenant` (`identity.company.update.config.emailSending.tenant`; string, required)
      - maxLength: `64` · minLength: `1`
  - `locale` (`identity.company.update.config.locale`; string, optional)
  - `timezone` (`identity.company.update.config.timezone`; string, optional)
- `displayName` (`identity.company.update.displayName`; string, optional)
  - maxLength: `128` · minLength: `1`
- `status` (`identity.company.update.status`; string, optional)
  - one of `"active"`, `"suspended"`

## Example request

```json
{
  "config": {
    "bookingSite": {
      "advisorSites": true,
      "enabled": true,
      "handle": "string"
    },
    "branding": {
      "accentColor": "string",
      "backgroundColor": "string",
      "bodyFont": "Inter",
      "borderColor": "string",
      "contact": {
        "email": "user@example.com",
        "instagram": "string",
        "phone": "string",
        "whatsapp": "string"
      },
      "faviconUrl": "string",
      "headingFont": "Inter",
      "hero": {
        "imageUrl": "http://example.com",
        "subtitle": "string",
        "title": "string"
      },
      "logoDarkUrl": "http://example.com",
      "logoUrl": "string",
      "mode": "light",
      "mutedTextColor": "string",
      "primaryColor": "string",
      "privacyUrl": "http://example.com",
      "radius": 24,
      "seo": {
        "description": "string",
        "title": "string"
      },
      "surfaceColor": "string",
      "textColor": "string"
    },
    "emailSending": {
      "checkedAt": "string",
      "dkimTokens": [
        "string"
      ],
      "domain": "string",
      "status": "FAILED",
      "tenant": "string"
    },
    "locale": "string",
    "timezone": "string"
  },
  "displayName": "string",
  "status": "active"
}
```

## Code samples

### JavaScript SDK

```javascript
import { createClient } from "@nicertravel/sdk";

const nicer = createClient({
  baseUrl: "https://api.nicer.travel",
  token: process.env.NICER_TOKEN,
});

await nicer.identity.company.update({
  "companyName": "string"
});
```

### Nicer CLI

```bash
nicer identity company update --company-name 'string' --input - <<'JSON'
{}
JSON
```

### cURL

```bash
curl --request PUT \
  --url 'https://api.nicer.travel/identity/company/<companyName>' \
  --header 'Authorization: Bearer <token>' \
  --header 'Content-Type: application/json' \
  --data '
{
  "config": {
    "bookingSite": {
      "advisorSites": true,
      "enabled": true,
      "handle": "string"
    },
    "branding": {
      "accentColor": "string",
      "backgroundColor": "string",
      "bodyFont": "Inter",
      "borderColor": "string",
      "contact": {
        "email": "user@example.com",
        "instagram": "string",
        "phone": "string",
        "whatsapp": "string"
      },
      "faviconUrl": "string",
      "headingFont": "Inter",
      "hero": {
        "imageUrl": "http://example.com",
        "subtitle": "string",
        "title": "string"
      },
      "logoDarkUrl": "http://example.com",
      "logoUrl": "string",
      "mode": "light",
      "mutedTextColor": "string",
      "primaryColor": "string",
      "privacyUrl": "http://example.com",
      "radius": 24,
      "seo": {
        "description": "string",
        "title": "string"
      },
      "surfaceColor": "string",
      "textColor": "string"
    },
    "emailSending": {
      "checkedAt": "string",
      "dkimTokens": [
        "string"
      ],
      "domain": "string",
      "status": "FAILED",
      "tenant": "string"
    },
    "locale": "string",
    "timezone": "string"
  },
  "displayName": "string",
  "status": "active"
}
'
```

### TypeScript

```typescript
const url = 'https://api.nicer.travel/identity/company/<companyName>';
const options = {
  method: 'PUT',
  headers: {
    'Content-Type': 'application/json',
    Authorization: 'Bearer <token>'
  },
  body: JSON.stringify({
    config: {
      bookingSite: {advisorSites: true, enabled: true, handle: 'string'},
      branding: {
        accentColor: 'string',
        backgroundColor: 'string',
        bodyFont: 'Inter',
        borderColor: 'string',
        contact: {
          email: 'user@example.com',
          instagram: 'string',
          phone: 'string',
          whatsapp: 'string'
        },
        faviconUrl: 'string',
        headingFont: 'Inter',
        hero: {imageUrl: 'http://example.com', subtitle: 'string', title: 'string'},
        logoDarkUrl: 'http://example.com',
        logoUrl: 'string',
        mode: 'light',
        mutedTextColor: 'string',
        primaryColor: 'string',
        privacyUrl: 'http://example.com',
        radius: 24,
        seo: {description: 'string', title: 'string'},
        surfaceColor: 'string',
        textColor: 'string'
      },
      emailSending: {
        checkedAt: 'string',
        dkimTokens: ['string'],
        domain: 'string',
        status: 'FAILED',
        tenant: 'string'
      },
      locale: 'string',
      timezone: 'string'
    },
    displayName: 'string',
    status: 'active'
  })
};

fetch(url, options)
  .then(res => res.json())
  .then(json => console.log(json))
  .catch(err => console.error(err));
```

### Python

```python
import requests

url = "https://api.nicer.travel/identity/company/<companyName>"

payload = {
    "config": {
        "bookingSite": {
            "advisorSites": True,
            "enabled": True,
            "handle": "string"
        },
        "branding": {
            "accentColor": "string",
            "backgroundColor": "string",
            "bodyFont": "Inter",
            "borderColor": "string",
            "contact": {
                "email": "user@example.com",
                "instagram": "string",
                "phone": "string",
                "whatsapp": "string"
            },
            "faviconUrl": "string",
            "headingFont": "Inter",
            "hero": {
                "imageUrl": "http://example.com",
                "subtitle": "string",
                "title": "string"
            },
            "logoDarkUrl": "http://example.com",
            "logoUrl": "string",
            "mode": "light",
            "mutedTextColor": "string",
            "primaryColor": "string",
            "privacyUrl": "http://example.com",
            "radius": 24,
            "seo": {
                "description": "string",
                "title": "string"
            },
            "surfaceColor": "string",
            "textColor": "string"
        },
        "emailSending": {
            "checkedAt": "string",
            "dkimTokens": ["string"],
            "domain": "string",
            "status": "FAILED",
            "tenant": "string"
        },
        "locale": "string",
        "timezone": "string"
    },
    "displayName": "string",
    "status": "active"
}
headers = {
    "Content-Type": "application/json",
    "Authorization": "Bearer <token>"
}

response = requests.put(url, json=payload, headers=headers)

print(response.text)
```

## Responses

### 200

OK

#### Example

```json
{
  "companyName": "string",
  "config": {},
  "createdAt": "string",
  "createdBy": "string",
  "displayName": "string",
  "status": "active",
  "updatedAt": "string",
  "type": "Company"
}
```

- `companyName` (`identity.company.update.response.200.companyName`; string, required)
  - minLength: `1`
- `config` (`identity.company.update.response.200.config`; object, required)
  - default: `{}`
  - `bookingSite` (`identity.company.update.response.200.config.bookingSite`; object, optional)
    - `advisorSites` (`identity.company.update.response.200.config.bookingSite.advisorSites`; boolean, optional)
    - `enabled` (`identity.company.update.response.200.config.bookingSite.enabled`; boolean, optional)
    - `handle` (`identity.company.update.response.200.config.bookingSite.handle`; string, optional)
  - `branding` (`identity.company.update.response.200.config.branding`; object, optional)
    - `accentColor` (`identity.company.update.response.200.config.branding.accentColor`; string, optional)
      - pattern: `^#[0-9a-fA-F]{6}$`
    - `backgroundColor` (`identity.company.update.response.200.config.branding.backgroundColor`; string, optional)
      - pattern: `^#[0-9a-fA-F]{6}$`
    - `bodyFont` (`identity.company.update.response.200.config.branding.bodyFont`; string, optional)
      - one of `"Inter"`, `"DM Sans"`, `"Manrope"`, `"Poppins"`, `"Montserrat"`, `"Lato"`, `"Nunito"`, `"Work Sans"`, `"Playfair Display"`, `"Merriweather"`, `"Lora"`, `"Cormorant Garamond"`
    - `borderColor` (`identity.company.update.response.200.config.branding.borderColor`; string, optional)
      - pattern: `^#[0-9a-fA-F]{6}$`
    - `contact` (`identity.company.update.response.200.config.branding.contact`; object, optional)
      - `email` (`identity.company.update.response.200.config.branding.contact.email`; string, optional)
        - format: `email` · maxLength: `254` · pattern: `^(?!\.)(?!.*\.\.)([A-Za-z0-9_'+\-\.]*)[A-Za-z0-9_+-]@([A-Za-z0-9][A-Za-z0-9\-]*\.)+[A-Za-z]{2,}$`
      - `instagram` (`identity.company.update.response.200.config.branding.contact.instagram`; string, optional)
        - maxLength: `64`
      - `phone` (`identity.company.update.response.200.config.branding.contact.phone`; string, optional)
        - maxLength: `32`
      - `whatsapp` (`identity.company.update.response.200.config.branding.contact.whatsapp`; string, optional)
        - maxLength: `32`
    - `faviconUrl` (`identity.company.update.response.200.config.branding.faviconUrl`; string, optional)
    - `headingFont` (`identity.company.update.response.200.config.branding.headingFont`; string, optional)
      - one of `"Inter"`, `"DM Sans"`, `"Manrope"`, `"Poppins"`, `"Montserrat"`, `"Lato"`, `"Nunito"`, `"Work Sans"`, `"Playfair Display"`, `"Merriweather"`, `"Lora"`, `"Cormorant Garamond"`
    - `hero` (`identity.company.update.response.200.config.branding.hero`; object, optional)
      - `imageUrl` (`identity.company.update.response.200.config.branding.hero.imageUrl`; string, optional)
        - format: `uri` · maxLength: `2048`
      - `subtitle` (`identity.company.update.response.200.config.branding.hero.subtitle`; string, optional)
        - maxLength: `160`
      - `title` (`identity.company.update.response.200.config.branding.hero.title`; string, optional)
        - maxLength: `80`
    - `logoDarkUrl` (`identity.company.update.response.200.config.branding.logoDarkUrl`; string, optional)
      - format: `uri` · maxLength: `2048`
    - `logoUrl` (`identity.company.update.response.200.config.branding.logoUrl`; string, optional)
    - `mode` (`identity.company.update.response.200.config.branding.mode`; string, optional)
      - one of `"light"`, `"dark"`, `"system"`
    - `mutedTextColor` (`identity.company.update.response.200.config.branding.mutedTextColor`; string, optional)
      - pattern: `^#[0-9a-fA-F]{6}$`
    - `primaryColor` (`identity.company.update.response.200.config.branding.primaryColor`; string, optional)
    - `privacyUrl` (`identity.company.update.response.200.config.branding.privacyUrl`; string, optional)
      - format: `uri` · maxLength: `2048`
    - `radius` (`identity.company.update.response.200.config.branding.radius`; integer, optional)
      - maximum: `24` · minimum: `0`
    - `seo` (`identity.company.update.response.200.config.branding.seo`; object, optional)
      - `description` (`identity.company.update.response.200.config.branding.seo.description`; string, optional)
        - maxLength: `160`
      - `title` (`identity.company.update.response.200.config.branding.seo.title`; string, optional)
        - maxLength: `60`
    - `surfaceColor` (`identity.company.update.response.200.config.branding.surfaceColor`; string, optional)
      - pattern: `^#[0-9a-fA-F]{6}$`
    - `textColor` (`identity.company.update.response.200.config.branding.textColor`; string, optional)
      - pattern: `^#[0-9a-fA-F]{6}$`
  - `emailSending` (`identity.company.update.response.200.config.emailSending`; object, optional)
    - `checkedAt` (`identity.company.update.response.200.config.emailSending.checkedAt`; string, required)
    - `dkimTokens` (`identity.company.update.response.200.config.emailSending.dkimTokens`; array of string, required)
      - minLength: `1`
    - `domain` (`identity.company.update.response.200.config.emailSending.domain`; string, required)
      - maxLength: `253` · minLength: `1`
    - `status` (`identity.company.update.response.200.config.emailSending.status`; string, required)
      - one of `"FAILED"`, `"PENDING"`, `"VERIFIED"`
    - `tenant` (`identity.company.update.response.200.config.emailSending.tenant`; string, required)
      - maxLength: `64` · minLength: `1`
  - `locale` (`identity.company.update.response.200.config.locale`; string, optional)
  - `timezone` (`identity.company.update.response.200.config.timezone`; string, optional)
- `createdAt` (`identity.company.update.response.200.createdAt`; string, required)
- `createdBy` (`identity.company.update.response.200.createdBy`; string, required)
  - minLength: `1`
- `displayName` (`identity.company.update.response.200.displayName`; string, required)
  - minLength: `1`
- `status` (`identity.company.update.response.200.status`; string, required)
  - one of `"active"`, `"suspended"`
- `updatedAt` (`identity.company.update.response.200.updatedAt`; string, required)
- `type` (`identity.company.update.response.200.type`; string, required)

### 400

Request failed. `errorCode` is stable; `errorMessage` is for humans.

#### Example

```json
{
  "errorCode": "string",
  "errorMessage": "string"
}
```

- `errorCode` (`identity.company.update.response.400.errorCode`; string, required)
- `errorMessage` (`identity.company.update.response.400.errorMessage`; string, required)

### 401

Request failed. `errorCode` is stable; `errorMessage` is for humans.

#### Example

```json
{
  "errorCode": "string",
  "errorMessage": "string"
}
```

- `errorCode` (`identity.company.update.response.401.errorCode`; string, required)
- `errorMessage` (`identity.company.update.response.401.errorMessage`; string, required)

### 403

Request failed. `errorCode` is stable; `errorMessage` is for humans.

#### Example

```json
{
  "errorCode": "string",
  "errorMessage": "string"
}
```

- `errorCode` (`identity.company.update.response.403.errorCode`; string, required)
- `errorMessage` (`identity.company.update.response.403.errorMessage`; string, required)


Source: https://docs.nicer.travel/api/identity/identity.company.update/index.md
