openapi: 3.2.0 info: title: Upsun.com Rest Phone Number API version: '1.0' contact: name: Support url: https://upsun.com/contact-us/ termsOfService: https://upsun.com/trust-center/legal/tos/ description: '# Introduction Upsun, formerly Platform.sh, is a container-based Platform-as-a-Service.' x-logo: url: https://docs.upsun.com/images/upsun-api.svg href: https://upsun.com/#section/Introduction altText: Upsun logo servers: - url: '{schemes}://api.upsun.com' description: The Upsun.com API gateway variables: schemes: default: https security: - OAuth2: [] tags: - name: Phone Number paths: /users/{user_id}/phonenumber: parameters: - $ref: '#/components/parameters/UserID' post: summary: Verify phone number description: Starts a phone number verification session. operationId: verify-phone-number tags: - Phone Number responses: '200': description: OK content: application/json: schema: type: object properties: sid: type: string description: Session ID of the verification. '400': description: Bad Request content: application/json: schema: $ref: '#/components/schemas/Error' '403': description: Forbidden content: application/json: schema: $ref: '#/components/schemas/Error' '409': description: Conflict content: application/json: schema: $ref: '#/components/schemas/Error' requestBody: content: application/json: schema: type: object properties: channel: type: string description: The channel used to receive the verification code. enum: - sms - whatsapp - call phone_number: type: string description: The phone number used to receive the verification code. required: - channel - phone_number /users/{user_id}/phonenumber/{sid}: parameters: - schema: type: string name: sid in: path required: true description: The session ID obtained from `POST /users/{user_id}/phonenumber`. - $ref: '#/components/parameters/UserID' post: summary: Confirm phone number description: Confirms phone number using a verification code. operationId: confirm-phone-number tags: - Phone Number responses: '200': description: OK '400': description: Bad Request content: application/json: schema: $ref: '#/components/schemas/Error' '403': description: Forbidden content: application/json: schema: $ref: '#/components/schemas/Error' '409': description: Conflict content: application/json: schema: $ref: '#/components/schemas/Error' requestBody: content: application/json: schema: type: object properties: code: type: string description: The verification code received on your phone. required: - code components: parameters: UserID: name: user_id in: path required: true description: The ID of the user. schema: type: string example: d81c8ee2-44b3-429f-b944-a33ad7437690 format: uuid schemas: Error: description: '' type: object properties: status: type: string message: type: string code: type: number detail: type: object title: type: string title: '' x-examples: example-1: status: Invalid input message: This field is required. code: 400 detail: field: - This field is required. title: Bad Request securitySchemes: OAuth2: type: oauth2 flows: authorizationCode: tokenUrl: https://auth.api.platform.sh/oauth2/token refreshUrl: https://auth.api.platform.sh/oauth2/token scopes: {} authorizationUrl: https://auth.api.platform.sh/oauth2/authorize description: '' OAuth2Admin: type: oauth2 flows: clientCredentials: tokenUrl: https://auth.api.platform.sh/oauth2/token refreshUrl: '' scopes: admin: administrative operations description: '' x-tagGroups: - name: Organization Administration tags: - Organizations - Organization Members - Organization Invitations - Organization Projects - Add-ons - name: Project Administration tags: - Project - Domain Management - Cert Management - Certificate Provisioner - Project Variables - Repository - Third-Party Integrations - Support - name: Environments tags: - Environment - Environment Backups - Environment Type - Environment Variables - Routing - Source Operations - Runtime Operations - Deployment - Autoscaling - name: User Activity tags: - Project Activity - Environment Activity - name: Project Access tags: - Project Invitations - Teams - Team Access - User Access - name: Account Management tags: - API Tokens - Connections - MFA - Users - User Profiles - SSH Keys - Plans - name: Billing tags: - Organization Management - Subscriptions - Orders - Invoices - Discounts - Vouchers - Records - Profiles - name: Global Info tags: - Project Discovery - References - Regions - name: Internal APIs tags: - Project Settings - Environment Settings - Deployment Target - System Information - Container Profile