---
title: "Create User Relationship"
method: POST
path: "/v2/user-relationships"
tags: ["User Relationship API"]
---

# Create User Relationship

`POST /v2/user-relationships`

Create or update a user relationship. If a relationship already exists, it will be updated.

## Request body

- SvauthPublicCreateUserRelationshipRequest
  - `userId` string, required
  - `relatedUserId` string, required
  - `relationshipType` 'USER_RELATIONSHIP_TYPE_UNSPECIFIED' | 'USER_RELATIONSHIP_TYPE_MANAGER', required

## Response `200`

Success

- SvauthPublicCreateUserRelationshipResponse
  - `data` SvauthPublicUserRelationship
    - `userId` string
    - `relatedUserId` string
    - `relationshipType` 'USER_RELATIONSHIP_TYPE_UNSPECIFIED' | 'USER_RELATIONSHIP_TYPE_MANAGER'
    - `createdAt` string, date-time — A timestamp in RFC 3339 format (e.g., "2025-01-15T01:30:15Z").

## Other responses

- `default` — Error

---

[API](https://skmtc.net/serval/apis/serval-public-api.md) · [All operations](https://skmtc.net/serval/apis/serval-public-api/llms.txt) · [OpenAPI document](https://skmtc-service-staging.skmtc.workers.dev/v1/apis/serval/serval-public-api/versions/0549515e9384/schema)
