openapi: 3.2.0 info: title: Nokia Network As Code Number Verification v1.0.0 API version: 1.0.0 termsOfService: https://developer.networkascode.nokia.io/legal/terms-of-service x-refined-note: - x-badges differs across the merged source definitions and was not carried - x-camara-commonalities differs across the merged source definitions and was not carried - x-category differs across the merged source definitions and was not carried - x-collections differs across the merged source definitions and was not carried - x-long-description differs across the merged source definitions and was not carried - x-public differs across the merged source definitions and was not carried - x-thumbnail differs across the merged source definitions and was not carried - x-version-lifecycle differs across the merged source definitions and was not carried - x-website differs across the merged source definitions and was not carried description: 'Operations tagged Number Verification v1.0.0 across 2 of this provider''s published API definitions: nokia-network-as-code-camara-openapi.yml, nokia-network-as-code-platform-openapi.json. Each path carries the servers of the definition it was published in.' servers: - url: '{apiRoot}/geofencing-subscriptions/v0.3' variables: apiRoot: default: http://localhost:9091 description: API root - url: '{apiRoot}/geofencing-subscriptions/v0.4' variables: apiRoot: default: http://localhost:9091 description: API root - url: https://network-as-code.p-eu.rapidapi.com tags: - name: Number Verification v1.0.0 paths: /passthrough/camara/v1/number-verification/number-verification/v0/verify: post: tags: - Number Verification v1.0.0 summary: Verifies if the received hashed/plain text phone number matches the phone number associated with the access token description: 'Verifies if the specified phone number (either in plain text or hashed format) matches the one that the user is currently using. Only one of the plain or hashed formats must be provided. - The number verification will be done for the user that has authenticated via mobile network - It returns true/false depending on if the hashed phone number received as input matches the authenticated user''s `device phone number` associated to the access token ' operationId: phoneNumberVerify parameters: - in: header name: x-correlator required: false description: Correlation id for the different services schema: type: string - in: header name: authorization required: false description: authorization header for token schema: type: string - in: query name: code required: false description: Authorization code received from the CSP schema: type: string - in: query name: state required: false description: Application state schema: type: string requestBody: content: application/json: schema: $ref: '#/components/schemas/NumberVerificationRequestBody-NV-V1' examples: NUMBER_VERIFY_TRUE_PHONE_NUMBER: value: phoneNumber: '+99999991000' NUMBER_VERIFY_FALSE_PHONE_NUMBER: value: phoneNumber: '+99999991001' required: true responses: '200': description: OK headers: x-correlator: description: Correlation id for the different services schema: type: string content: application/json: schema: $ref: '#/components/schemas/NumberVerificationMatchResponse-NV-V1' '400': $ref: '#/components/responses/Generic400-NV-V1' '401': $ref: '#/components/responses/Generic401-NV-V1' '403': $ref: '#/components/responses/PhoneNumberVerificationPermissionDenied403-NV-V1' '500': $ref: '#/components/responses/Generic500-NV-V1' '503': $ref: '#/components/responses/Generic503-NV-V1' '504': $ref: '#/components/responses/Generic504-NV-V1' security: - openId: - number-verification:verify servers: - url: '{apiRoot}/geofencing-subscriptions/v0.3' variables: apiRoot: default: http://localhost:9091 description: API root - url: '{apiRoot}/geofencing-subscriptions/v0.4' variables: apiRoot: default: http://localhost:9091 description: API root /passthrough/camara/v1/number-verification/number-verification/v0/device-phone-number: get: tags: - Number Verification v1.0.0 summary: Returns the phone number associated with the access token description: 'Returns the phone number so the API clients can verify the number themselves: - It will be done for the user that has authenticated via mobile network - It returns the authenticated user''s `device phone number` associated to the access token ' operationId: phoneNumberShare parameters: - in: header name: x-correlator required: false description: Correlation id for the different services schema: type: string - in: header name: authorization required: false description: authorization header for token schema: type: string - in: query name: code required: false description: Authorization code received from the CSP schema: type: string - in: query name: state required: false description: Application state schema: type: string responses: '200': description: OK headers: x-correlator: description: Correlation id for the different services schema: type: string content: application/json: schema: $ref: '#/components/schemas/NumberVerificationShareResponse-NV-V1' '400': $ref: '#/components/responses/Generic400-NV-V1' '401': $ref: '#/components/responses/Generic401-NV-V1' '403': $ref: '#/components/responses/PhoneNumberVerificationPermissionDenied403-NV-V1' '500': $ref: '#/components/responses/Generic500-NV-V1' '503': $ref: '#/components/responses/Generic503-NV-V1' '504': $ref: '#/components/responses/Generic504-NV-V1' security: - openId: - number-verification:device-phone-number:read servers: - url: '{apiRoot}/geofencing-subscriptions/v0.3' variables: apiRoot: default: http://localhost:9091 description: API root - url: '{apiRoot}/geofencing-subscriptions/v0.4' variables: apiRoot: default: http://localhost:9091 description: API root components: schemas: DevicePhoneNumberVerified-NV-V1: description: Number verification. True, if it matches type: boolean NumberVerificationShareResponse-NV-V1: type: object description: Number verification share result required: - devicePhoneNumber properties: devicePhoneNumber: $ref: '#/components/schemas/DevicePhoneNumber-NV-V1' NumberVerificationRequestBody-NV-V1: type: object description: Payload to verify the phone number. minProperties: 1 maxProperties: 1 properties: phoneNumber: type: string pattern: ^\+[1-9][0-9]{4,14}$ example: '+123456789' description: A public identifier addressing a telephone subscription. In mobile networks it corresponds to the MSISDN (Mobile Station International Subscriber Directory Number). In order to be globally unique it has to be formatted in international format, according to E.164 standard, prefixed with '+'. hashedPhoneNumber: description: Hashed phone number. SHA-256 (in hexadecimal representation) of the mobile phone number in **E.164 format (starting with country code)**. Prefixed with '+'. type: string example: 32f67ab4e4312618b09cd23ed8ce41b13e095fe52b73b2e8da8ef49830e50dba ErrorInfo-NV-V1: type: object required: - status - code - message properties: status: type: integer description: HTTP response status code code: type: string description: Code given to this error message: type: string description: Detailed error description DevicePhoneNumber-NV-V1: type: string pattern: ^\+[1-9][0-9]{4,14}$ example: '+123456789' description: A public identifier addressing a telephone subscription. In mobile networks it corresponds to the MSISDN (Mobile Station International Subscriber Directory Number). In order to be globally unique it has to be formatted in international format, according to E.164 standard, prefixed with '+'. NumberVerificationMatchResponse-NV-V1: type: object description: Number verification result required: - devicePhoneNumberVerified properties: devicePhoneNumberVerified: $ref: '#/components/schemas/DevicePhoneNumberVerified-NV-V1' responses: Generic504-NV-V1: description: Request time exceeded. If it happens repeatedly, consider reducing the request complexity headers: x-correlator: $ref: '#/components/headers/x-correlator-NV-V1' content: application/json: schema: $ref: '#/components/schemas/ErrorInfo-NV-V1' example: status: 504 code: TIMEOUT message: Request timeout exceeded. Try later. Generic401-NV-V1: description: Unauthorized headers: x-correlator: $ref: '#/components/headers/x-correlator-NV-V1' content: application/json: schema: $ref: '#/components/schemas/ErrorInfo-NV-V1' examples: GENERIC_401_UNAUTHENTICATED: description: Request cannot be authenticated value: status: 401 code: UNAUTHENTICATED message: Request not authenticated due to missing, invalid, or expired credentials. GENERIC_401_AUTHENTICATION_REQUIRED: description: New authentication is needed, authentication is no longer valid value: status: 401 code: AUTHENTICATION_REQUIRED message: New authentication is required. Generic503-NV-V1: description: Service unavailable. Typically the server is down. headers: x-correlator: $ref: '#/components/headers/x-correlator-NV-V1' content: application/json: schema: $ref: '#/components/schemas/ErrorInfo-NV-V1' example: status: 503 code: UNAVAILABLE message: Service unavailable Generic500-NV-V1: description: Server error headers: x-correlator: $ref: '#/components/headers/x-correlator-NV-V1' content: application/json: schema: $ref: '#/components/schemas/ErrorInfo-NV-V1' example: status: 500 code: INTERNAL message: Server error Generic400-NV-V1: description: Problem with the client request headers: x-correlator: $ref: '#/components/headers/x-correlator-NV-V1' content: application/json: schema: $ref: '#/components/schemas/ErrorInfo-NV-V1' example: status: 400 code: INVALID_ARGUMENT message: Client specified an invalid argument, request body or query param PhoneNumberVerificationPermissionDenied403-NV-V1: description: "Client does not have sufficient permission.\nIn addition to regular scenario of `PERMISSION_DENIED`, other scenarios may exist:\n\n\n\n\n - Client authentication was not via mobile network. In order to check the authentication method, AMR parameter value in the 3-legged user's access token can be used and make sure that the authentication was not either by SMS+OTP nor username/password (`{\"code\": \"NUMBER_VERIFICATION.USER_NOT_AUTHENTICATED_BY_MOBILE_NETWORK\",\"message\": \"Client must authenticate via the mobile network to use this service\"}`)\n - Phone number cannot be deducted from access token context.(`{\"code\": \"INVALID_TOKEN_CONTEXT\",\"message\": \"Phone number cannot be deducted from access token context\"}`)\n" headers: x-correlator: $ref: '#/components/headers/x-correlator-NV-V1' content: application/json: schema: $ref: '#/components/schemas/ErrorInfo-NV-V1' examples: GENERIC_403_PERMISSION_DENIED: description: Permission denied. OAuth2 token access does not have the required scope or when the user fails operational security value: status: 403 code: PERMISSION_DENIED message: Client does not have sufficient permissions to perform this action. GENERIC_403_USER_NOT_AUTHENTICATED_BY_MOBILE_NETWORK: value: status: 403 code: NUMBER_VERIFICATION.USER_NOT_AUTHENTICATED_BY_MOBILE_NETWORK message: Client must authenticate via the mobile network to use this service GENERIC_403_INVALID_TOKEN_CONTEXT: value: status: 403 code: INVALID_TOKEN_CONTEXT message: Phone number cannot be deducted from access token context headers: x-correlator-NV-V1: description: Correlation id for the different services schema: type: string parameters: x-rapidapi-host: name: x-rapidapi-host in: header required: true description: The API's Host value as defined in the RapidAPI Hub. schema: type: string example: network-as-code.p-eu.rapidapi.com securitySchemes: openId: description: OpenID Connect authentication type: openIdConnect openIdConnectUrl: https://example.com/.well-known/openid-configuration ApiKeyAuth: type: apiKey in: header name: x-rapidapi-key description: Your RapidAPI key externalDocs: description: Project documentation at Camara url: https://github.com/camaraproject/DeviceLocation x-refined-from: - nokia-network-as-code-camara-openapi.yml - nokia-network-as-code-platform-openapi.json