2

We have an external service which we send data (a JSON) to them, with some details - that also includes personal data such as mobile phone number and country ISO code.

I would like to use the Google service (libphonenumber - https://github.com/google/libphonenumber) to check the validity of a mobile phone number in a specific country.

All of this needs to happen on the server-side.

how can I install a package on my org and use it in Apex code? (This is even possible?)

1 Answer 1

4

You should be able to use Salesforce Functions to do this, but the program is still in Beta, meaning you have to sign up for it, and it likely won't be available in Production orgs for a while. Until then, you can always spin something up on Heroku or another service, and make a callout to get the results you want. Of course, you can't callout during a trigger, so you'll need some asynchronous code or flow if you need it to trigger on a DML operation, but the main point is that options are available to you if you absolutely need this server-side.

1
  • Many thanks. Heroku is great idea !
    – Salvation
    Commented Aug 25, 2021 at 16:41

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .