Incoming number normalize

Hi I’m new asterisk user so can you help how can I normalize my incoming numbers.
For example:
I’d like to use a standard format: [color=green]+359[/color][color=darkblue]2[/color][color=darkred]9718585[/color]
[color=green]+359[/color] Country code; [color=darkblue]2[/color] Area code; [color=darkred]9718585[/color] Phone number

And actually from my ISDN provider I see: [color=darkblue]02[/color][color=darkred]9718585[/color]
[color=darkblue]02[/color] area code [color=darkred]9718585[/color]phone number
How can I make some rules?
If I see prefix 0 to remove 0 and put [color=green]+359[/color] and
And if the prefix is 00 to remove 00 and to put +
And if it possible to use this rule only for ISND TRUNC (adapter).
Thx in advance.

Something like this, in the appropriate context in the dialplan, may do it but I never tried with the +'s: -

exten => _00.,1, Goto(+${EXTEN:2}) exten => _0[1-9].,1, Goto(+359${EXTEN:1})