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

# Edit a company

> Update editable fields on an owned company.

Updates profile, contact, share, shareholder, and social details for a claimed company. The request is `multipart/form-data` so shareholder ID documents can be attached in the same call. Most fields are sent as flat form fields; `shareHolderDetails`, `registrarInfo`, and `socials` are JSON-encoded.

## Path

<ParamField path="companyId" type="string" required>
  The company must be owned by the caller.
</ParamField>

## Form fields

All fields are optional. Send each as a separate `multipart/form-data` part.

<ParamField body="companyName" type="string" />

<ParamField body="rcNumber" type="string" />

<ParamField body="email" type="string" />

<ParamField body="phone" type="string" />

<ParamField body="address" type="string" />

<ParamField body="city" type="string" />

<ParamField body="state" type="string" />

<ParamField body="postcode" type="string" />

<ParamField body="natureOfBusiness" type="string" />

<ParamField body="businessCategory" type="string" />

<ParamField body="businessDescription" type="string" />

<ParamField body="headOfficeAddress" type="string" />

<ParamField body="company_classification" type="string" />

<ParamField body="firsTin" type="string" />

<ParamField body="shareCapital" type="string | number" />

<ParamField body="vouchShareCapital" type="string | number" />

<ParamField body="shareCapitalInWords" type="string" />

<ParamField body="dividedInto" type="string" />

<ParamField body="registrationApproved" type="string | boolean" />

<ParamField body="active" type="string | boolean" />

<ParamField body="website_verified" type="string | boolean" />

<ParamField body="shareHolderVerified" type="boolean" />

<ParamField body="shareHolder" type="boolean">
  When `true`, the response echoes the updated `shareHolderDetails` array instead of the trimmed `company` object.
</ParamField>

<ParamField body="socials" type="object">
  JSON-encoded. Keys: `website`, `facebook`, `instagram`, `linkedin`, `twitter`, `tiktok` (each a URL). A reachable `website` flips `website_verified` to `true`.
</ParamField>

<ParamField body="registrarInfo" type="string | object">
  JSON-encoded. Keys: `surname`, `firstname`, `email`, `nationality`, `date_of_birth`.
</ParamField>

<ParamField body="shareHolderDetails" type="string | array">
  JSON-encoded array. Each shareholder may include `name`, `email`, `address`, `dateOfBirth`, `nationality`, `idType`, `roleInCompany`, `percentageOfOwner`, `noOfShares`, `identificationNumber`, `phoneNumber`, `identificationDocumentUrl`. Supplying this array sets `shareHolderVerified` to `true`.
</ParamField>

<ParamField body="shareholderIdDocs" type="file[]">
  Up to 10 PDFs, ≤ 50 MB each. Files are matched to shareholders **by position** — the first file applies to the first entry in `shareHolderDetails`, the second to the second, and so on. Each uploaded document is verified against the shareholder's `name`, `identificationNumber`, and `idType` before it is stored; a shareholder with no matching file keeps its existing document. Extra files beyond the shareholder count are ignored.
</ParamField>

<RequestExample>
  ```bash cURL theme={null}
  curl -X POST https://api.vouchmark.com/v1/edit-company/cmp_aBcD... \
    -H "Authorization: Bearer $TOKEN" \
    -F 'city=Lagos' \
    -F 'state=Lagos' \
    -F 'socials={"website":"https://tekcify.com"}' \
    -F 'shareHolderDetails=[{"name":"Ada Obi","email":"ada@tekcify.com","idType":"NIN","identificationNumber":"12345678901","noOfShares":5000}]' \
    -F 'shareholderIdDocs=@./ada-nin.pdf'
  ```
</RequestExample>

<ResponseExample>
  ```json Company update theme={null}
  {
    "success": true,
    "message": "Company details updated successfully",
    "company": {
      "id": "cmp_aBcD...",
      "shareHolderDetails": [
        {
          "name": "Ada Obi",
          "email": "ada@tekcify.com",
          "idType": "NIN",
          "identificationNumber": "12345678901",
          "noOfShares": 5000,
          "identificationDocumentUrl": "https://cdn.vouchmark.com/..."
        }
      ]
    }
  }
  ```

  ```json Shareholder update (shareHolder=true) theme={null}
  {
    "success": true,
    "message": "Shareholder details updated successfully",
    "shareHolderDetails": []
  }
  ```

  ```json Address-only update theme={null}
  {
    "success": true,
    "message": "Address information updated successfully"
  }
  ```
</ResponseExample>

<Note>
  If no owned company matches `companyId`, the endpoint returns `404` with `{ "message": "Company not found" }`. Invalid shareholder JSON returns `400` with `{ "message": "Invalid JSON data provided" }`.
</Note>
