Ethical spoofing

I have a request prior to deploying a FreePBX for a client. In this case, it’s a doctor, and he has 2 published numbers. One for general office, and one for his surgery center. He wants to be able to output either number as he makes an outbound call. Doing it on his analog lines is simple. Just select the line and dial. Now I know we can assign an outbound ANI per phone on the PBX, but this client wants to do it from each phone by pressing a button prior to dialing.I can do it with other PBX’s, Panasonic for example. But can I do this on a FreePBX using Poly or Panasonic phones, or something like them?

I call this ethical spoofing because this guy has the numbers already, and just wants to use them outbound.

Set 2 outbound routes, one for each CID. He’ll need to dial a prefix to select the route. “8” gets one route, “9” gets the other.

That assumes his provider let’s him set the CID.

Alternative option:
Configure 2 extensions on the same phone (if possible).
Set 2 outbound routes, one for each CID, take into account the source Caller Id (extension).
He’ll need to pick the right extension on the phone before making the call.

This may be overkill for 2 numbers but:

Okay, so I tried this, but I think I got something wrong. I set up 2 new routes, with local 7/10 digit patterns. Then in each pattern (per route) I set an 8 or 9 in the prepend field. I get a call can’t be made as dialed message. I guess my setup will use an outbound route only if it doesn’t find a match internally. So how do I get it to recognize the 8 or 9?

The 8 and 9 should be a prefix not a prepend
Prefix will strip off the prefix of the match and send only the match.
Prepend will add an 8 or 9 to your dialed string.
Both can be used together.