openapi: 3.0.3 info: title: Paperspace Container Registries Activity Startup Scripts API version: v1 description: 'Manage container registry credentials used by Paperspace Deployments to pull private images. Authenticate with a team-scoped API key as `Authorization: Bearer $API_TOKEN`. ' servers: - url: https://api.paperspace.com/v1 description: Production security: - bearerAuth: [] tags: - name: Startup Scripts paths: /startup-scripts: get: tags: - Startup Scripts operationId: listStartupScripts summary: List Startup Scripts description: Fetches a list of startup scripts. responses: '200': description: Script list. content: application/json: schema: type: array items: $ref: '#/components/schemas/StartupScript' post: tags: - Startup Scripts operationId: createStartupScript summary: Create Startup Script description: Generates a new startup script. requestBody: required: true content: application/json: schema: $ref: '#/components/schemas/StartupScriptCreate' responses: '201': description: Created script. content: application/json: schema: $ref: '#/components/schemas/StartupScript' /startup-scripts/{id}: parameters: - in: path name: id required: true schema: type: string get: tags: - Startup Scripts operationId: getStartupScript summary: Get Startup Script description: Fetches a single startup script by ID. responses: '200': description: Script. content: application/json: schema: $ref: '#/components/schemas/StartupScript' put: tags: - Startup Scripts operationId: updateStartupScript summary: Update Startup Script description: Modifies an existing startup script. requestBody: required: true content: application/json: schema: $ref: '#/components/schemas/StartupScriptCreate' responses: '200': description: Updated script. content: application/json: schema: $ref: '#/components/schemas/StartupScript' delete: tags: - Startup Scripts operationId: deleteStartupScript summary: Delete Startup Script description: Removes a startup script. responses: '204': description: Deleted. /startup-scripts/{id}/assign: parameters: - in: path name: id required: true schema: type: string post: tags: - Startup Scripts operationId: assignStartupScript summary: Assign Startup Script description: Links a startup script to a machine. requestBody: required: true content: application/json: schema: type: object required: - machineId properties: machineId: type: string responses: '200': description: Assigned. /startup-scripts/{id}/unassign: parameters: - in: path name: id required: true schema: type: string post: tags: - Startup Scripts operationId: unassignStartupScript summary: Unassign Startup Script description: Disconnects a startup script from a machine. requestBody: required: true content: application/json: schema: type: object required: - machineId properties: machineId: type: string responses: '200': description: Unassigned. components: schemas: StartupScript: type: object properties: id: type: string name: type: string runOnce: type: boolean isEnabled: type: boolean teamId: type: string dtCreated: type: string format: date-time StartupScriptCreate: type: object required: - name - script properties: name: type: string script: type: string runOnce: type: boolean isEnabled: type: boolean securitySchemes: bearerAuth: type: http scheme: bearer bearerFormat: api-key