---
title: "Create Permissions for a Resource"
method: POST
path: "/v1/permissions"
tags: ["Permissions"]
---

# Create Permissions for a Resource

`POST /v1/permissions`

Create permissions for a specific resource (such as a table, table view, or process).

## Request body

- CreatePermissions
  - `context` BaseRequestContext
    - `projectId` string, uuid
    - `processPublicId` string, uuid, nullable
    - `processSectionPublicId` string, uuid, nullable
    - `processResponsePublicId` string, uuid, nullable
  - `role` 0 | 1 | 2 | 3 | 4, required
  - `resourceKind` 'process' | 'table' | 'table_view', required
  - `resourceId` string, uuid, required
  - `attributeKind` 'user' | 'tag' | 'project' | 'all_table_tags', required
  - `attributeId` string, uuid
  - `tagReferenceId` string

## Response `200`

Successfully created permissions for the resource.

- object
  - `metadata` object
  - `data` AccessPolicy
    - `publicId` string, uuid
    - `accessAttribute` AccessAttribute
      - `publicId` string, uuid
      - `kind` string
      - `tag` Tag
        - `publicId` string, uuid
        - `referencePublicId` string
        - `documentTableId` string
        - `value` unknown
        - `projectPublicId` string, uuid
      - `user` User5
        - `name` string
        - `publicId` string, uuid
        - `firebaseUserId` string
      - `project` Project
        - `publicId` string
        - `name` string
      - `documentTable` Table3
        - `name` string
        - `publicId` string, uuid
    - `accessResource` AccessResource
      - `publicId` string, uuid
      - `kind` string
      - `process` Document
        - `publicId` string, uuid
        - `name` string
      - `documentTable` Table3
        - `name` string
        - `publicId` string, uuid
    - `role` integer
    - `roleLabel` string

## Other responses

- `403` — Unauthorized action - User lacks necessary permissions.
- `404` — Resource or accessor not found.
- `422` — Validation error for the provided data.

---

[API](https://skmtc.net/morta-technology/apis/morta-api-reference.md) · [All operations](https://skmtc.net/morta-technology/apis/morta-api-reference/llms.txt) · [OpenAPI document](https://skmtc-service-staging.skmtc.workers.dev/v1/apis/morta-technology/morta-api-reference/revisions/9c58c1c1e7e8/schema)
