# Update limit config by Org Update the limit configuration for authorizations on the Org level. This endpoint updates the entire configuration, so you must send all fields to avoid data loss. # OpenAPI definition ```json { "openapi": "3.1.0", "info": { "title": "Core platform - Balance watcher", "description": "Balance watcher endpoints.", "contact": { "name": "API Support", "url": "https://developers.pismo.io/support/" }, "license": { "name": "Copyright Pismo" }, "version": "1.0.0" }, "servers": [ { "url": "https://sandbox.pismolabs.io/balance-watcher", "description": "Sandbox API server for testing" } ], "tags": [ { "name": "Limit configurations", "description": "Endpoints to support configuration operations" } ], "components": { "schemas": { "ConfigRequest": { "type": "object", "description": "Configuration record request", "properties": { "over_limit": { "$ref": "#/components/schemas/Overlimit" }, "limit_refund": { "$ref": "#/components/schemas/LimitRefund" } } }, "ConfigResponse": { "type": "object", "description": "Configuration record response", "properties": { "over_limit": { "$ref": "#/components/schemas/Overlimit" }, "limit_refund": { "$ref": "#/components/schemas/LimitRefund" } } }, "Error": { "type": "object", "properties": { "code": { "type": "string", "description": "Error code.", "example": "RCAPI-DOMAIN-VIOLATION" }, "message": { "type": "string", "description": "Error description.", "example": "RCAPI domain violation." } } }, "Overlimit": { "type": "object", "description": "Group of configurations related to the over-limit flow", "required": [ "enable" ], "properties": { "enable": { "type": "boolean", "description": "Flag to enable the over-limit feature.", "example": true } } }, "LimitRefund": { "type": "object", "description": "Group of configurations related to the limit refund flow", "required": [ "enable" ], "properties": { "enable": { "type": "boolean", "description": "Flag to enable the limit refund feature.", "example": true } } } }, "securitySchemes": { "BearerAuth": { "type": "http", "scheme": "bearer", "description": "Account access token. Tokens can expire quickly, which can result in an \"Unauthorized\" error.", "bearerFormat": "JWT" } } }, "security": [ { "BearerAuth": [] } ], "paths": { "/v1/config": { "put": { "summary": "Update limit config by Org", "description": "Update the limit configuration for authorizations on the Org level. This endpoint updates the entire configuration, so you must send all fields to avoid data loss.", "operationId": "put-config-by-tenant", "tags": [ "Limit configurations" ], "requestBody": { "description": "Update configuration request body", "required": true, "content": { "application/json": { "schema": { "$ref": "#/components/schemas/ConfigRequest" } } } }, "responses": { "200": { "description": "Updated successfully", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/ConfigResponse" } } } }, "400": { "description": "Bad request", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/Error" }, "example": { "code": "BW0008", "message": "Invalid request." } } } }, "401": { "description": "Unauthorized", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/Error" }, "example": { "code": "BW0031", "message": "Config creation by account unauthorized." } } } }, "404": { "description": "Not found", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/Error" }, "example": { "code": "BW0001", "message": "No configuration was found." } } } }, "500": { "description": "Internal server error", "content": { "application/json": { "schema": { "$ref": "#/components/schemas/Error" }, "example": { "code": "BW0007", "message": "An unexpected error happened." } } } } } } } } } ```