---
updatedAt: 2026-04-27T23:21:35.000Z
agentTools:
  projectIndex: https://developer.runn.io/llms.txt
---

# Allocate a view to a user

# OpenAPI definition

```json
{
  "openapi": "3.1.0",
  "info": {
    "title": "Runn API",
    "version": "1.0.0",
    "description": "<p>See <a target=\"_blank\" href=\"https://help.runn.io/en/articles/8579592-api-v1-beta\" title=\"Runn API full documentation\">the full documentation and guide</a> to using the Runn API.</p><p>The domain for your API endpoint can be found in <strong>Accounts > Settings > API</strong> in your Runn application</p>"
  },
  "components": {
    "securitySchemes": {
      "bearerAuth": {
        "type": "http",
        "scheme": "bearer"
      }
    },
    "schemas": {
      "Conflict": {
        "type": "object",
        "required": [
          "error",
          "message",
          "statusCode"
        ],
        "properties": {
          "error": {
            "type": "string",
            "enum": [
              "Conflict"
            ]
          },
          "message": {
            "type": "string"
          },
          "statusCode": {
            "type": "number",
            "enum": [
              409
            ]
          }
        }
      },
      "NotFound": {
        "type": "object",
        "required": [
          "error",
          "message",
          "statusCode"
        ],
        "properties": {
          "error": {
            "type": "string",
            "enum": [
              "Not Found"
            ]
          },
          "message": {
            "type": "string"
          },
          "statusCode": {
            "type": "number",
            "enum": [
              404
            ]
          }
        }
      },
      "Unauthorized": {
        "type": "object",
        "required": [
          "error",
          "message",
          "statusCode"
        ],
        "properties": {
          "error": {
            "type": "string",
            "enum": [
              "Unauthorized"
            ]
          },
          "message": {
            "type": "string",
            "enum": [
              "Unauthorized"
            ]
          },
          "statusCode": {
            "type": "number",
            "enum": [
              401
            ]
          }
        }
      }
    }
  },
  "paths": {
    "/users/{userId}/views/{viewId}": {
      "post": {
        "operationId": "createUserView",
        "summary": "Allocate a view to a user",
        "parameters": [
          {
            "schema": {
              "type": "integer"
            },
            "in": "path",
            "name": "userId",
            "required": true,
            "description": "The Id of the user to allocate the view to."
          },
          {
            "schema": {
              "type": "integer"
            },
            "in": "path",
            "name": "viewId",
            "required": true,
            "description": "The Id of the view to allocate to the user."
          },
          {
            "schema": {
              "default": "1.0.0",
              "enum": [
                "1.0.0"
              ]
            },
            "in": "header",
            "name": "accept-version",
            "required": true
          }
        ],
        "responses": {
          "201": {
            "description": "Default Response"
          },
          "401": {
            "description": "Default Response",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Unauthorized"
                }
              }
            }
          },
          "404": {
            "description": "Default Response",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/NotFound"
                }
              }
            }
          },
          "409": {
            "description": "Default Response",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Conflict"
                }
              }
            }
          }
        }
      }
    }
  },
  "servers": [
    {
      "url": "https://api.runn.io",
      "description": "EU Server"
    },
    {
      "url": "https://api.us.runn.io",
      "description": "US Server"
    }
  ],
  "security": [
    {
      "bearerAuth": []
    }
  ],
  "x-readme": {
    "proxy-enabled": false
  }
}
```