Xero - beautiful accounting software

Xero Developer Help Center

Xero Developer Community

Community > API Endpoints >

ContactNumber with an Ampersand

Started by Derek Hughes -   in API Endpoints

When setting the contactnumber field to use in a custom link, I don't seem to be able to get an ampersand from the contactnumber to render into the generated URL (as the value in contactnumber is the end of a query string value as I need to pass 2 values.

Any ideas?
Hi Derek,
Can you give a bit more information on where you're running into a problem? What generated URL do you mean?
 

Steven Brown (Xero Staff)  

Apologies, I thought I had replied to this yesterday...

I set a value that includes an ampersand into the contactnumber field (e.g. 1&id={guid}) when I am creating the contact during my integration. I then configure https://customer.crm6.dynamics.com/main.aspx?app=d365default&pagetype=entityrecord&etc={!CONTACTCODE} as a custom contact link(per https://go.xero.com/Contacts/ContactLinks.aspx), however the ampersand in {!contactcode} to finish my query string is URL encoded, so my URL doesn't work.
 

Derek Hughes  

So it looks like this is a bit outside of the API teams realm so I'm passing it along to the relevant team. Sorry I can't be of more help directly.
 

Steven Brown (Xero Staff)