---
title: "Generate headcount CSV and upload it to pigment"
method: POST
path: "/{domain}/v1/headcount/upload/pigment"
tags: ["Headcount"]
---

# Generate headcount CSV and upload it to pigment

`POST /{domain}/v1/headcount/upload/pigment`

## Request

- Base URL: `https://api.teamohana.us` (the document declares no server; this is the origin it was published from)
- URL: `https://api.teamohana.us/{domain}/v1/headcount/upload/pigment`
- Auth: HTTP bearer
- TypeScript: <https://skmtc.dev/teamohana/apis/teamohana-public-api/docs/:domain/v1/headcount/upload/pigment/post.ts> (a function with typed inputs; its response is checked against the schema)

Generate the headcount CSV and trigger an async upload to Pigment. Optionally pass time-period in the body (currently only `"this-year"` is supported) to scope the CSV to the org's current fiscal year. Refer to the [Pigment Connector API FAQ](/faq/index.html#pigment-connector-api) for more details.

## Path parameters

- `domain` string, required

## Request body

- object
  - `import-configuration-id` string, required
  - `time-period` 'this-year': Filter records whose effective start date falls within the org's current fiscal year. Valid values: this-year.

## Response `200`

A success message describing the result of the upload.

- string

## Other responses

- `400`: Missing or blank x-pigment-api-key header.
- `401`: Unauthorized
- `500`: Something went wrong. Please contact TeamOhana support.
- `503`: The upload could not be queued. Please retry.

---

[API](https://skmtc.dev/teamohana/apis/teamohana-public-api.md) - [All operations](https://skmtc.dev/teamohana/apis/teamohana-public-api/llms.txt) - [OpenAPI document](https://skmtc.dev/teamohana/apis/teamohana-public-api/revisions/87f9835cbb94?raw)
