Phone numbers using /persons/find

I want to add a phone number to a person if it is not already added.

I tried using the /persons/find endpoint to get a person by email, then to check if the specific phone number already exists for the person or not. However, it seems like that endpoint is just returning a single phone number (the primary one), is this correct? If so, why doesn’t return the person in the same format as /persons/{id}?

So to solve my scenario the only way I see is this:

  1. Find person using email address
  2. Get person using the id returned in step 1
  3. Check if any of the person’s phone number matches the number in question
  4. If no match: Use persons endpoint (PUT) to add phone number

Is this correct, or is there a smarter way?

All correct :slight_smile: