Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Adding a pattern for PhoneNumber in /verify #76

Closed
maxl2287 opened this issue Dec 12, 2023 · 1 comment
Closed

Adding a pattern for PhoneNumber in /verify #76

maxl2287 opened this issue Dec 12, 2023 · 1 comment
Labels
enhancement New feature or request

Comments

@maxl2287
Copy link
Contributor

Problem description
Currently the phoneNumber is not validated against a pattern.

Possible evolution

Add the following pattern to "phoneNumber":

pattern: '^\+?[0-9]{5,15}$'
    NumberVerificationRequestBody:
      type: object
      description: Payload to verify the phone number.
      minProperties: 1
      maxProperties: 1
      properties:
        phoneNumber:
          description: A phone number belonging to the user in **E.164 format (starting with country code)**. Optionally prefixed with '+'.
          type: string
          example: '+346661113334'
          pattern: '^\+?[0-9]{5,15}$'
      (...) 
@maxl2287 maxl2287 added the enhancement New feature or request label Dec 12, 2023
@DT-DawidWroblewski
Copy link
Collaborator

good discussion about pattern is here: #65

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

2 participants