---
title: "Create user PII request"
method: POST
path: "/v1/companies/{company_code_or_sid}/pii-requests"
tags: ["companies"]
---

# Create user PII request

`POST /v1/companies/{company_code_or_sid}/pii-requests`

## Request

- Base URL: `https://api.prod-us.streem.cloud`
- URL: `https://api.prod-us.streem.cloud/v1/companies/{company_code_or_sid}/pii-requests`
- Auth: one of:
  - HTTP basic
  - HTTP bearer
- TypeScript: <https://skmtc.dev/streem/apis/streem-api/docs/v1/companies/:company_code_or_sid/pii-requests/post.ts> (a function with typed inputs; its response is checked against the schema)

Requests all Personally Identifiable Information (PII) associated with a user

## Path parameters

- `company_code_or_sid` string, required

## Request body

- StreemApiCreatePiiRequestRequest
  - `external_user_id` string
  - `include_sub_companies` boolean
  - `custom_identifier` string
  - `webhook_url` string
  - `oauth_url` string
  - `oauth_url_properties` StreemApiOAuthUrlProperties
    - `grant_type` string
    - `client_id` string
    - `client_secret` string

## Response `200`

PII request was created successfully

- StreemApiCreatePiiRequestResponse
  - `pii_request_sid` string
  - `custom_identifier` string

## Other responses

- `400`: The provided webhook URL was missing or invalid
- `403`: You do not have permission to create a PII request
- `404`: The company specified does not exist
- `500`: Unable to create a PII request

---

[API](https://skmtc.dev/streem/apis/streem-api.md) - [All operations](https://skmtc.dev/streem/apis/streem-api/llms.txt) - [OpenAPI document](https://skmtc.dev/streem/apis/streem-api/revisions/04250faebd19?raw)
