Skip to Content

UpdatePolicy

PUT
/auth/v1/organizations/{org_id}/policies/{policy_id}

Authorization

headerX-API-Key<token>

API key for protected endpoints, supplied in the X-API-Key header.

Path Parameters

org_id*org_id
policy_id*policy_id

Request Body

required
application/json
{
  "name": "string",
  "description": "string",
  "permissions": [
    "string"
  ]
}
name?string
description?string
permissions?array<string>

Response Body

200application/json

Success

type: unknown

{
  "$ref": "#/components/schemas/auth.v1.Policy",
  "$ref-value": {
    "type": "object",
    "properties": {
      "id": {
        "type": "string",
        "title": "id"
      },
      "org_id": {
        "type": "string",
        "title": "org_id"
      },
      "name": {
        "type": "string",
        "title": "name"
      },
      "description": {
        "type": "string",
        "title": "description"
      },
      "permissions": {
        "type": "array",
        "items": {
          "type": "string"
        },
        "title": "permissions"
      },
      "created_by": {
        "type": "string",
        "title": "created_by"
      },
      "created_at": {
        "title": "created_at",
        "$ref": "#/components/schemas/google.protobuf.Timestamp",
        "$ref-value": {
          "type": "string",
          "examples": [
            "2023-01-15T01:30:15.01Z",
            "2024-12-25T12:00:00Z"
          ],
          "format": "date-time",
          "description": "A point in time in RFC 3339 format, with up to nanosecond precision. Output uses UTC (`Z`); input may use an offset from UTC."
        }
      },
      "updated_at": {
        "title": "updated_at",
        "$ref": "#/components/schemas/google.protobuf.Timestamp",
        "$ref-value": {
          "type": "string",
          "examples": [
            "2023-01-15T01:30:15.01Z",
            "2024-12-25T12:00:00Z"
          ],
          "format": "date-time",
          "description": "A point in time in RFC 3339 format, with up to nanosecond precision. Output uses UTC (`Z`); input may use an offset from UTC."
        }
      }
    },
    "title": "Policy",
    "additionalProperties": false
  }
}
default
curl -X PUT 'https://api.rixl.com/auth/v1/organizations/string/policies/string'

Success

application/json

{
  "$ref": "#/components/schemas/auth.v1.Policy",
  "$ref-value": {
    "type": "object",
    "properties": {
      "id": {
        "type": "string",
        "title": "id"
      },
      "org_id": {
        "type": "string",
        "title": "org_id"
      },
      "name": {
        "type": "string",
        "title": "name"
      },
      "description": {
        "type": "string",
        "title": "description"
      },
      "permissions": {
        "type": "array",
        "items": {
          "type": "string"
        },
        "title": "permissions"
      },
      "created_by": {
        "type": "string",
        "title": "created_by"
      },
      "created_at": {
        "title": "created_at",
        "$ref": "#/components/schemas/google.protobuf.Timestamp",
        "$ref-value": {
          "type": "string",
          "examples": [
            "2023-01-15T01:30:15.01Z",
            "2024-12-25T12:00:00Z"
          ],
          "format": "date-time",
          "description": "A point in time in RFC 3339 format, with up to nanosecond precision. Output uses UTC (`Z`); input may use an offset from UTC."
        }
      },
      "updated_at": {
        "title": "updated_at",
        "$ref": "#/components/schemas/google.protobuf.Timestamp",
        "$ref-value": {
          "type": "string",
          "examples": [
            "2023-01-15T01:30:15.01Z",
            "2024-12-25T12:00:00Z"
          ],
          "format": "date-time",
          "description": "A point in time in RFC 3339 format, with up to nanosecond precision. Output uses UTC (`Z`); input may use an offset from UTC."
        }
      }
    },
    "title": "Policy",
    "additionalProperties": false
  }
}