---
title: "POST /v1/orgs/{orgId}/dsync"
method: POST
path: "/v1/orgs/{orgId}/dsync"
tags: ["Orgs"]
---

# POST /v1/orgs/{orgId}/dsync

`POST /v1/orgs/{orgId}/dsync`

## Request

- Base URL: `https://api.tessl.io`
- URL: `https://api.tessl.io/v1/orgs/{orgId}/dsync`
- Auth: none declared
- TypeScript: <https://skmtc.dev/tessl/apis/tessl-api/docs/v1/orgs/:orgId/dsync/post.ts> (a function with typed inputs; its response is checked against the schema)

Generates a WorkOS Admin Portal link for configuring Directory Sync. The link is single-use and expires after about 5 minutes. Restricted to org admins, and returns 404 unless groups are enabled for the org.

## Path parameters

- `orgId` string, uuid, required

## Headers

- `Authorization` string

## Request body

- object
  - `returnUrl` string

## Response `201`

Default Response

- object
  - `links` object, required
    - `self` string, uri, required
  - `data` object, required
    - `id` string, uuid, required
    - `type` 'directory-sync-portal-link', required
    - `attributes` object, required
      - `link` string, uri, required

## Other responses

- `400`: Bad Request
- `401`: Unauthorized
- `403`: Forbidden
- `404`: Not Found
- `500`: Internal Server Error

## Changes

- **2026-11-06** `de4ee98f763e`: 1 info
  - endpoint added

[Operation history](https://skmtc.dev/tessl/apis/tessl-api/changes/v1/orgs/:orgId/dsync/post.md)

---

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