Manipulating just one digit of caller ID on forwarded calls in FreePBX

I’m trying to set up caller ID passing with call forwarding on my FreePBX 2.9 system… but with a slight twist.

Here’s what I’d like to do:

I’d like to forward calls to DID 1 to go to my cell phone. I would like to pass the caller ID of the caller to my cell phone, EXCEPT I would like to modify it in some way (if possible) to tell me that the call is being passed from my phone system, as opposed to my cell number being directly dialed.

Here’s an example: Caller 618-555-1212 calls my phone system. In the event of forwarding, I’d like it to go to my cell phone but pass something like 118-555-1212 (118 instead of 618) on caller ID so I can still see the caller’s number (mostly), but tell that my cell wasn’t directly dialed, but that it came through my phone system.

Better yet, perhaps it could pass 118 if the call was to DID 1, then 218 if the call was to DID 2, et cetera.

Is this doable? Or perhaps there’s some smarter way to accomplish this?


You’re not the first person to ask this question.

There is no way to do it in the GUI. With the GUI, you could force a specific caller ID so that you’d know it was coming from your phone system, but you’d lose the Caller’s caller-id.

There may be a way to do it by manually editing the FreePBX related files, but I don’t know what it is.

Search the forums. Sumbit a feature request.

I searched around, but couldn’t find anything that was relevant.

Outside of the GUI, do you know if this is doable? If it could be done through manually editing some files, then that might be a good solution, so long as it wouldn’t “break” the GUI.

Thanks for the answer!

I would like to see this, but I would prefer to see the caller ID passed fully. Right now all I see on my cellphone is “Private” when passed from my system. Even if I set the trunks to pass caller ID.
Just seeing my home number would be nice with maybe and asterisk on the end of the format! so 515 555 1212* would indicate it was coming from a forwarded number off my system.

That would be nice, too. Just something to tell us that the call came from the system.

I am still trying to figure a way of my caller ID coming over to my cellphone. As I mentioned, I am still getting “PRIVATE” come up on mine… lol

The Follow me and ring group modules both allow you to prepend caller ID info.


It looks like those only allow you to prepend text or names to the caller ID. If I’m thinking right, that doesn’t get passed on to a cell phone’s caller ID.

I don’t suppose there’s a way to prepend the number or replace the first digit of the number or something?

If you place only a numeric value it will be inserted and passed on to the cell phone.

Of course this only works if your provider allows you to assert caller ID. I suggest that if you are using a primary provider that does not allow this to simply sign up for a pay as you go SIP account provider such as Flowroute.

That sounds promising. I don’t quite have it working yet, so I must be missing something.

In the Follow Me settings for the extension, I have “CID Name Prefix” set to “9.” This, however, doesn’t get passed along to the cell phone when I make a call.

Under “Change External CID Configuration,” if I set the Mode to “Fixed CID Value” and put in “6185551212” as the number, that does indeed get passed to my phone.

Also, if I change it to “Default” or to “Forced Dialed Number,” I will get the appropriate number, but in none of the cases is the 9 getting prepended and sent to the cell phone. It’s essentially being ignored.

One possible solution I can think of would be to use a variable. For instance if I could change the external CID to “Fixed CID Value,” and then put in something like “9$caller_number” or something like that, it seems like that would work.

I must be missing something, but I can’t figure out just what it is!

Thanks for the help, by the way!

P.S. deanot26508 – what DID provider do you use? I’m on, and they seem to have no trouble passing CID. Perhaps your provider does not allow it, as SkykingOH has suggested.

When you say “dialing your number” I am not sure what you mean.

If you have a DID mapped to follow me or a ring group and the “CID name prefix” populate that numeric data will be prepended to the caller ID of any targets listed in the ring group or follow me list.

Does this make sense?

It does make sense, but for some reason it’s still not working properly.

Here’s a screenshot of my extension settings and the Follow Me settings:

The portion that’s blocked out is my incoming DID that is associated with this extension. When I dial that DID from another phone, Extension 211 rings, as well as my cell phone (represented by 6185551234).

The caller ID that is being passed to my cell phone is indeed the caller ID of the phone I’m dialing from. So the caller ID is being passed with no problem, but the “9” isn’t getting prepended.

On my SIP phone that is Ext 211 (a Grandstream GXP-2000, if it matters), the CID does show up as 9 + the CID of the calling phone.

So it appears the prepending is working as expected with the SIP phone, but once it gets to the cell phone, it isn’t prepending anything.

Take a look at the debug log, (SIP and dial plan) and see if it is being sent to the carrier, maybe they reject that string.

Do you just get the standard CID on the cell?

Only for CNAM, which isn’t passed outside of your own system. Ring Groups and Follow me don’t allow you to prepend the CID number.

SkyKing is mistaken here and you are correct. The CID Name Prefix will not be passed to your cellular phone because in the US, no provider passes along CNAM. They all use lookup tables. There is no way to accomplish what you want from the GUI.

You can use the Change External Caller ID option to force a special Caller ID to tell you that the call is coming from your system, but that will erase the source Caller ID altogether.

I guess the real question is: Why do you care that the call is coming through the system? Don’t you really just care WHO is calling you?

If you want to be alerted that the call is coming from the system, send the call through its own ring group, and enable the confirm calls feature. That’ll cause the system to play a recording when you answer the call, and you’ll have to press 1 to take it.

Hey, confirmed calls might be a perfect solution.

I was wanting to mangle the original caller ID to let me know it was from the system. For instance, if the original caller was 618-555-1212, I was thinking if I have 018-555-1212 or something like that, I would still recognize the number but with the one digit being changed I would realize the call was being forwarded to me.

I like the idea of confirmed calls even better, though, because then the CID stays intact, and if I have somebody in my cell phone’s address book, it will match and show their name.

And SkyKing: I do just get the “standard” caller ID, with no text. Just the 10-digit number. I wasn’t expecting for my cell phone to receive the text, but was wondering if I could alter the first of the 10 digits or something to that effect.

Thanks, guys!

I never said the a cell phone could receive text updates, numeric only.

If you do not use alphanumeric in the prepend field it should send in text mode.