openapi: 3.0.4 info: title: Calyptia Cloud agent core_instance_secret API version: '1.0' description: HTTP API service of Calyptia Cloud contact: name: Calyptia email: hello@calyptia.com url: https://cloud.calyptia.com termsOfService: https://calyptia.com/terms/ servers: - url: https://cloud-api.calyptia.com description: prod - url: https://cloud-api-dev.calyptia.com description: dev - url: https://cloud-api-staging.calyptia.com description: staging - url: http://localhost:{port} description: local variables: port: default: '5000' tags: - name: core_instance_secret paths: /v1/core_instances/{coreInstanceID}/secrets: parameters: - name: coreInstanceID in: path schema: type: string format: uuid required: true post: operationId: createCoreInstanceSecret summary: Create Core Instance Secret description: 'Create a new secret within a core instance. The secret will be created with the given name and content. If `encypted` is set to `true`, the secret will be encrypted using the core instance''s encryption key. The name must be unique among all secrets within the core instance.' tags: - core_instance_secret security: - user: [] - project: [] requestBody: content: application/json: schema: $ref: '#/components/schemas/CreateCoreInstanceSecret' responses: '201': description: Created content: application/json: schema: $ref: '#/components/schemas/Created' get: operationId: coreInstanceSecrets summary: Core Instance Secrets description: Secrets from a core instance with backward pagination. tags: - core_instance_secret security: - user: [] - project: [] parameters: - name: last schema: type: integer minimum: 0 in: query description: Limit to the last secrets. - name: before schema: type: string in: query description: Paginate secrets before the given cursor. responses: '200': description: OK content: application/json: schema: $ref: '#/components/schemas/CoreInstanceSecrets' /v1/core_instance_secrets/{coreInstanceSecretID}: parameters: - name: coreInstanceSecretID in: path schema: type: string format: uuid required: true patch: operationId: updateCoreInstanceSecret summary: Update Core Instance Secret description: 'Update a secret within a core instance. The secret will be updated with the given name and content. If `encypted` is set to `true`, the secret will be encrypted using the core instance''s encryption key.' tags: - core_instance_secret security: - user: [] - project: [] requestBody: content: application/json: schema: $ref: '#/components/schemas/UpdateCoreInstanceSecret' responses: '200': description: OK content: application/json: schema: $ref: '#/components/schemas/Updated' delete: operationId: deleteCoreInstanceSecret summary: Delete Core Instance Secret description: Delete a secret within a core instance. tags: - core_instance_secret security: - user: [] - project: [] responses: '200': description: OK content: application/json: schema: $ref: '#/components/schemas/Deleted' components: schemas: Created: type: object properties: id: type: string format: uuid createdAt: type: string format: date-time required: - id - createdAt CoreInstanceSecrets: type: object properties: items: type: array items: $ref: '#/components/schemas/CoreInstanceSecret' endCursor: type: string nullable: true count: type: number format: int32 required: - items - endCursor - count Deleted: type: object properties: deleted: type: boolean deletedAt: type: string format: date-time nullable: true default: null required: - deleted - deletedAt Updated: type: object properties: updatedAt: type: string format: date-time required: - updatedAt CoreInstanceSecret: type: object properties: id: type: string format: uuid coreInstanceID: type: string format: uuid key: type: string example: mysecret value: type: string format: byte description: 'The value of the secret in base 64 format. The value is always encrypted.' createdAt: type: string format: date-time updatedAt: type: string format: date-time required: - id - coreInstanceID - key - value - createdAt - updatedAt CreateCoreInstanceSecret: type: object properties: key: type: string example: mysecret value: type: string format: byte description: The value of the secret in base 64 format. required: - key - value - encrypted UpdateCoreInstanceSecret: type: object properties: key: type: string nullable: true default: null example: mysecret value: type: string format: byte nullable: true default: null description: Optional value of the secret in base 64 format. securitySchemes: user: type: http scheme: bearer project: name: X-Project-Token type: apiKey in: header auth0: type: oauth2 flows: clientCredentials: tokenUrl: https://sso.calyptia.com/oauth/token scopes: {} authorizationCode: authorizationUrl: https://sso.calyptia.com/authorize tokenUrl: https://sso.calyptia.com/oauth/token scopes: {}