72
Views
15
Comments
API for mobile number validation with country code for different countries.
Question

Hi All I need to implement an API for mobile number validation for different countries with different country codes.  

2019-08-28 11-43-22
Bruno Marques

Hi,

See if this post helps you.

Regards

2023-12-07 13-05-35
Akshata Tallur

Hi,

I need to use API not forge component.

2024-07-05 14-16-55
Daniël Kuhlmann
 
MVP

Most Forge components are just abstractions on top of an API, so not sure what your issue is with a Forge component.

2022-08-03 04-32-50
Ravi Punjwani

Hi Akshata,

Do you mean a server side action and not a client side action? Are you doing some validation inside server actions and nothing related to UI?

And do you require this so you can expose the server actions as a REST API, or public actions for other modules to use? Am I overthinking? In your post description, you mentioned "I need to implement an API for mobile number", and then in a recent reply, you mentioned, I need to "use" API. Please suggest what is your use case?

2023-12-07 13-05-35
Akshata Tallur

Hi Ravi Yes I need to do some mobile validation for different countries could you pls assist me how it is done using REST API.

2022-08-03 04-32-50
Ravi Punjwani

Try using a third-party library from forge components like CleaveJS or something similar.

2022-11-10 11-02-46
Sandeep Mallah

Hi,

You can create a Entity and with country name and country code and create logic with input parameter and validate information with entity after that you can return validation information.

Regards,

Sandeep Mallah


2023-12-07 13-05-35
Akshata Tallur

Hi All could anybody assist me on how to validate mobile number using REST API.

2022-08-03 04-32-50
Ravi Punjwani

@Akshata Tallur its very difficult to help when the question is not proper and having missing information.

Kindly give some screenshots and the purpose you want to use "API". It can be done without API, it can be done using javascript, client actions, server actions, REST API, third party libraries etc.

It all depends on what's your scenario. Do you have a UI involved in your use case? If yes, then you can create your client or server actions, without any API. If there's no UI, then provide more details how this validation feature will be used.

2023-12-07 13-05-35
Akshata Tallur
Hi Ravi PFB snap when will enter mobile no and validate I should get the response. Could you pls assist on it.
2022-08-03 04-32-50
Ravi Punjwani

Hi Akshata, is this Traditional Web or Reactive Web app?

2023-12-07 13-05-35
Akshata Tallur
2023-12-07 13-05-35
Akshata Tallur

Hi Ravi,

I tried using the forge component but while entering the phone number and validating it. I am not getting a proper result. It gives me correct result only when I add the Phone Number using dialling code. My actual implementation should be I should enter only 10 digit mobile number and validate the number.

Community GuidelinesBe kind and respectful, give credit to the original source of content, and search for duplicates before posting.