openapi: 3.2.0 info: title: Huma Platform Invitations API version: 1.0.0 description: Huma Platform servers: - url: https://workspace-gcp-uk.api.huma.com/api/integration/v1 description: Base URL declared by the provider in apis.yml (roadmap#122). tags: - name: Invitations paths: /api/extensions/v1/deployment/create-patient-profile: post: operationId: api_extensions_v1_deployment_create_patient_profile_create_[create_patient_profile] summary: Create Patient Profile tags: - Invitations requestBody: content: application/json: schema: $ref: '#/components/schemas/CreatePatientProfileRequestObjectDRF' application/x-www-form-urlencoded: schema: $ref: '#/components/schemas/CreatePatientProfileRequestObjectDRF' multipart/form-data: schema: $ref: '#/components/schemas/CreatePatientProfileRequestObjectDRF' required: true security: - JWT Auth: [] - Hawk Auth: [] - jwtAuth: [] responses: '201': content: application/json: schema: $ref: '#/components/schemas/CreatePatientProfileResponseObjectDRF' description: '' /api/extensions/v1/deployment/invitation: delete: operationId: api_extensions_v1_deployment_invitation_destroy_[delete_invitation_list] summary: Delete Invitation List tags: - Invitations security: - JWT Auth: [] - Hawk Auth: [] - jwtAuth: [] responses: '200': content: application/json: schema: $ref: '#/components/schemas/DeleteInvitationsListResponseDRF' description: '' /api/extensions/v1/deployment/invitation-link: post: operationId: api_extensions_v1_deployment_invitation_link_create_[get_invitation_link] summary: Get Invitation Link tags: - Invitations requestBody: content: application/json: schema: $ref: '#/components/schemas/GetInvitationLinkRequestDataDRF' application/x-www-form-urlencoded: schema: $ref: '#/components/schemas/GetInvitationLinkRequestDataDRF' multipart/form-data: schema: $ref: '#/components/schemas/GetInvitationLinkRequestDataDRF' required: true security: - JWT Auth: [] - Hawk Auth: [] - jwtAuth: [] responses: '200': content: application/json: schema: $ref: '#/components/schemas/GetInvitationLinkResponseObjectDRF' description: '' /api/extensions/v1/deployment/invitation/{invitation_id}: delete: operationId: api_extensions_v1_deployment_invitation_destroy_[delete_invitation] summary: Delete Invitation parameters: - in: path name: invitation_id schema: type: string pattern: ^[a-f0-9]{24}$ required: true tags: - Invitations security: - JWT Auth: [] - Hawk Auth: [] - jwtAuth: [] responses: '204': description: No response body /api/extensions/v1/deployment/invitations: post: operationId: api_extensions_v1_deployment_invitations_create_[retrieve_invitations_v1] summary: Retrieve Invitations V1 tags: - Invitations requestBody: content: application/json: schema: $ref: '#/components/schemas/RetrieveInvitationsRequestDataDRF' application/x-www-form-urlencoded: schema: $ref: '#/components/schemas/RetrieveInvitationsRequestDataDRF' multipart/form-data: schema: $ref: '#/components/schemas/RetrieveInvitationsRequestDataDRF' required: true security: - JWT Auth: [] - Hawk Auth: [] - jwtAuth: [] responses: '200': content: application/json: schema: $ref: '#/components/schemas/RetrieveInvitationsV1ResponseObjectDRF' description: '' /api/extensions/v1/deployment/resend-invitation-list: post: operationId: api_extensions_v1_deployment_resend_invitation_list_create_[resend_user_invitation_list] description: Resend User Invitations summary: Resend User Invitation List tags: - Invitations requestBody: content: application/json: schema: $ref: '#/components/schemas/ResendInvitationsListRequestObjectDRF' application/x-www-form-urlencoded: schema: $ref: '#/components/schemas/ResendInvitationsListRequestObjectDRF' multipart/form-data: schema: $ref: '#/components/schemas/ResendInvitationsListRequestObjectDRF' required: true security: - JWT Auth: [] - Hawk Auth: [] - jwtAuth: [] responses: '200': content: application/json: schema: $ref: '#/components/schemas/ResendInvitationsListResponseDRF' description: '' /api/extensions/v1/deployment/send-invitation: post: operationId: api_extensions_v1_deployment_send_invitation_create_[send_user_invitation_v1] description: Send User invitation V1 summary: Send User Invitation V1 tags: - Invitations requestBody: content: application/json: schema: $ref: '#/components/schemas/SendInvitationsRequestDataV1DRF' application/x-www-form-urlencoded: schema: $ref: '#/components/schemas/SendInvitationsRequestDataV1DRF' multipart/form-data: schema: $ref: '#/components/schemas/SendInvitationsRequestDataV1DRF' required: true security: - JWT Auth: [] - Hawk Auth: [] - jwtAuth: [] responses: '202': content: application/json: schema: $ref: '#/components/schemas/SendInvitationsResponseObjectV1DRF' description: '' /api/extensions/v1/deployment/send-invitation/{user_id}: post: operationId: api_extensions_v1_deployment_send_invitation_create_[send_user_specific_invitation] summary: Send User Specific Invitation parameters: - in: path name: user_id schema: type: string pattern: ^[a-f0-9]{24}$ required: true tags: - Invitations requestBody: content: application/json: schema: $ref: '#/components/schemas/SendUserSpecificInvitationRequestObjectDRF' application/x-www-form-urlencoded: schema: $ref: '#/components/schemas/SendUserSpecificInvitationRequestObjectDRF' multipart/form-data: schema: $ref: '#/components/schemas/SendUserSpecificInvitationRequestObjectDRF' required: true security: - JWT Auth: [] - Hawk Auth: [] - jwtAuth: [] responses: '200': description: No response body /api/public/v1/invitation-validity/{invitation_code}: get: operationId: api_public_v1_invitation_validity_retrieve_[invitation_validity_check] description: 'Check invitation validity Checks if invitation code is valid or not' summary: Invitation Validity Check parameters: - in: path name: invitation_code schema: type: string required: true tags: - Invitations security: - {} responses: '200': content: application/json: schema: $ref: '#/components/schemas/InvitationValidityResponseObjectDRF' description: '' components: schemas: InviteeDRF: type: object properties: givenName: type: string familyName: type: string email: type: string contactEmail: type: string phoneNumber: type: string userId: type: string InvitationResponseModelDRF: type: object properties: id: type: string email: type: string contactEmail: type: string phoneNumber: type: string text: type: string code: type: string shortenedCode: type: string givenName: type: string familyName: type: string roles: type: array items: $ref: '#/components/schemas/RoleAssignmentDTODRF' numberOfTry: type: integer expiresAt: type: string format: date-time createDateTime: type: string format: date-time updateDateTime: type: string format: date-time senderId: type: string clientId: type: string language: type: string extraInfo: type: object additionalProperties: {} type: type: string status: type: string deferredLink: type: string deferredLinkExpiresAt: type: string format: date-time deepLinkValue: type: string ssoEnabled: type: boolean userId: type: string roleName: type: string invitationLink: type: string invitedBy: type: string required: - code - expiresAt SendUserSpecificInvitationRequestObjectDRF: type: object properties: language: type: string clientId: type: string projectId: type: string expiresIn: type: string linkExpiresIn: type: string invitationType: type: string text: type: string email: type: string phoneNumber: type: string required: - clientId - invitationType - projectId SendInvitationsRequestDataV1DRF: type: object properties: language: type: string clientId: type: string projectId: type: string roleId: type: string organizationId: type: string deploymentIds: type: array items: type: string type: type: string text: type: string patientId: type: string invitees: type: array items: $ref: '#/components/schemas/InviteeDRF' expiresIn: type: string required: - clientId - projectId - roleId - type ResendInvitationsListResponseDRF: type: object properties: resentInvitations: type: integer InvitationValidityResponseObjectDRF: type: object properties: ok: type: boolean invitationCode: type: string email: type: string phoneNumber: type: string role: type: string InvitationItemDRF: type: object properties: invitationCode: type: string invitationId: type: string email: type: string phoneNumber: type: string text: type: string RetrieveInvitationsV1ResponseObjectDRF: type: object properties: invitations: type: array items: $ref: '#/components/schemas/InvitationResponseModelDRF' filtered: type: integer total: type: integer RetrieveInvitationsRequestDataDRF: type: object properties: language: type: string clientId: type: string projectId: type: string email: type: string search: type: string userId: type: string roleType: type: string skip: type: integer limit: type: integer invitationType: type: string sortFields: type: array items: $ref: '#/components/schemas/SortFieldDRF' required: - clientId - limit - projectId - roleType - skip SortFieldDRF: type: object properties: field: type: string direction: type: string required: - direction - field CreatePatientProfileResponseObjectDRF: type: object properties: userId: type: string ok: type: boolean required: - userId SendInvitationsResponseObjectV1DRF: type: object properties: alreadySignedUpEmails: type: array items: type: string alreadySignedUpPhoneNumbers: type: array items: type: string alreadyInvitedPhoneNumbers: type: array items: type: string ids: type: array items: type: string failedSendInvitePhoneNumbers: type: array items: type: string ok: type: boolean GetInvitationLinkResponseObjectDRF: type: object properties: link: type: string RoleAssignmentDTODRF: type: object properties: roleId: type: string resource: type: string userType: type: string isActive: type: boolean required: - resource - roleId ResendInvitationsListRequestObjectDRF: type: object properties: language: type: string clientId: type: string projectId: type: string invitationsList: type: array items: $ref: '#/components/schemas/InvitationItemDRF' required: - clientId - invitationsList - projectId GetInvitationLinkRequestDataDRF: type: object properties: language: type: string clientId: type: string projectId: type: string deploymentId: type: string roleId: type: string expiresIn: type: string retrieveShortened: type: boolean userId: type: string required: - clientId - deploymentId - projectId - roleId CreatePatientProfileRequestObjectDRF: type: object properties: givenName: type: string familyName: type: string dateOfBirth: type: string format: date-time email: type: string gender: type: string phoneNumber: type: string deploymentId: type: string required: - dateOfBirth - deploymentId - familyName - givenName DeleteInvitationsListResponseDRF: type: object properties: deletedInvitations: type: integer securitySchemes: Hawk_Auth: type: apiKey in: header name: Authorization description: 'Hawk MAC authentication. Paste a full Authorization header value. Example: Authorization: Hawk id="userId:clientId", ts="", nonce="", mac=""[, hash=""][, ext=""] Note: Swagger UI cannot generate Hawk headers. Use your client to compute the MAC (e.g., with mohawk), then paste the full value here.' JWT_Auth: type: http scheme: bearer in: header bearerFormat: JWT description: 'Use HTTP Bearer auth with a JWT. Send the token in the Authorization header: Authorization: Bearer The token should contain standard claims plus projectId and clientId in user claims.' jwtAuth: type: http scheme: bearer bearerFormat: JWT