# Response deserialization error - CRM Extension

**URL:** <https://community.hubspot.com/t/response-deserialization-error-crm-extension/18918>\
**Category:** APIs & Integrations\
**Tags:** timeline-and-extensions-apis\
**Created:** [February 20, 2020, 10:29am UTC](https://community.hubspot.com/t/response-deserialization-error-crm-extension/18918 "2020-02-20T10:29:35Z")\
**Posts on this page:** 9\
**Page:** 1

<div class="post-metadata">

**Author:** ![PaulAlmond91](https://d10pqhm3lwygmk.cloudfront.net/user_avatar/community.hubspot.com/paulalmond91/32/48165_2.png) [@PaulAlmond91](https://community.hubspot.com/u/PaulAlmond91)\
**Post date:** [February 20, 2020, 10:29am UTC](https://community.hubspot.com/t/response-deserialization-error-crm-extension/18918/1 "2020-02-20T10:29:35Z")

</div>

I have created an integration with our app and have successfully made this work without including a link.

This morning I have attempted to add the link and I’m receiving the response deserialization error which I understand is that the output is not matching the required format/fields.

Here is the json that I am returning

```auto
{
 "results":[
 {
 "objectId":124783,
 "title":"Presentation and Public Speaking Skills",
 "link":"https://tswt.administrateapp.com/beta#/events/events/31823#students",
 "type":"Delegate",
 "status":"attended",
 "event_start":"2019-12-10T09:00:00Z",
 "event_end":"2019-12-11T09:00:00Z",
 "attendance":100
 },
 {
 "objectId":124781,
 "title":"Time Management",
 "link":"https://tswt.administrateapp.com/beta#/events/events/31794#students",
 "type":"Delegate",
 "status":"attended",
 "event_start":"2019-12-02T09:00:00Z",
 "event_end":"2019-12-02T09:00:00Z",
 "attendance":100
 },
 {
 "objectId":116803,
 "title":"Time Management",
 "link":"https://tswt.administrateapp.com/beta#/events/events/31792#students",
 "type":"Delegate",
 "status":"cancelled",
 "event_start":"2019-06-07T09:00:00Z",
 "event_end":"2019-06-07T09:00:00Z",
 "attendance":0
 },
 {
 "objectId":115684,
 "title":"Mental Health Awareness",
 "link":"https://tswt.administrateapp.com/beta#/events/events/32951#students",
 "type":"Delegate",
 "status":"cancelled",
 "event_start":"2019-04-02T09:00:00Z",
 "event_end":"2019-04-02T09:00:00Z",
 "attendance":0
 },
 {
 "objectId":116095,
 "title":"Time Management",
 "link":"https://tswt.administrateapp.com/beta#/events/events/31790#students",
 "type":"Delegate",
 "status":"cancelled",
 "event_start":"2019-01-29T09:00:00Z",
 "event_end":"2019-01-29T09:00:00Z",
 "attendance":0
 },
 {
 "objectId":112287,
 "title":"HABC Emergency First Aid at Work",
 "link":"https://tswt.administrateapp.com/beta#/events/events/30881#students",
 "type":"Delegate",
 "status":"attended",
 "event_start":"2018-09-21T09:00:00Z",
 "event_end":"2018-09-21T09:00:00Z",
 "attendance":100
 },
 {
 "objectId":105933,
 "title":"Customer Service & Complaint Handling",
 "link":"https://tswt.administrateapp.com/beta#/events/events/29721#students",
 "type":"Delegate",
 "status":"attended",
 "event_start":"2018-03-29T09:00:00Z",
 "event_end":"2018-03-29T09:00:00Z",
 "attendance":100
 }
 ],
 "totalCount":7,
 "allItemLink":"https://tswt.administrateapp.com/ViewContact/view/id/29883",
 "itemLabel":"View all Events"
}

```

I’m pretty sure it is to do with the link but I cannot identify the cause. I’ve checked the usual issues (making sure a link is set or is null etc) but no joy. Any advice?

---

<div class="post-metadata">

**Author:** ![WendyGoh](https://d10pqhm3lwygmk.cloudfront.net/user_avatar/community.hubspot.com/wendygoh/32/42320_2.png) [@WendyGoh](https://community.hubspot.com/u/WendyGoh)\
**Post date:** [February 21, 2020, 4:14am UTC](https://community.hubspot.com/t/response-deserialization-error-crm-extension/18918/2 "2020-02-21T04:14:28Z")

</div>

Hey @PaulAlmond91,

Digging into this it looks like your hypothesis was correct! The error is likely due to the link property and two things I noticed here:

1. When I remove the symbol ‘#’, the CRM card shows up just fine with no error

2. When I attempted to add the following link ‘_[https://tswt.administrateapp.com/beta#/events/events/31823#students](https://tswt.administrateapp.com/beta#/events/events/31823#students)_’ under ‘Custom actions’ tab to allowlist it, it throws a ‘_The provided URI was not valid_’ error when saving it

In this case, it looks like this is due to an invalid uri link. Could you try removing the ‘#’ and see if it works for you?

---

<div class="post-metadata">

**Author:** ![PaulAlmond91](https://d10pqhm3lwygmk.cloudfront.net/user_avatar/community.hubspot.com/paulalmond91/32/48165_2.png) [@PaulAlmond91](https://community.hubspot.com/u/PaulAlmond91)\
**Post date:** [February 21, 2020, 8:29am UTC](https://community.hubspot.com/t/response-deserialization-error-crm-extension/18918/3 "2020-02-21T08:29:36Z")

</div>

Hi @WendyGoh

Yeah it appears it doesn’t like the #students at the end.

Another query just as it is happening - I included the allItemLink in hopes that would limit the results displayed and show a view all link at the bottom akin to what is shown here: [Accounts Dashboard | HubSpot](https://developers.hubspot.com/docs/methods/crm-extensions/crm-extensions-overview) (where it says view all 7 tickets)

However, the above output displays all entries on the screen and no view more link. Have I overlooked or structured the output incorrectly to enable this feature?

---

<div class="post-metadata">

**Author:** ![WendyGoh](https://d10pqhm3lwygmk.cloudfront.net/user_avatar/community.hubspot.com/wendygoh/32/42320_2.png) [@WendyGoh](https://community.hubspot.com/u/WendyGoh)\
**Post date:** [February 24, 2020, 1:23am UTC](https://community.hubspot.com/t/response-deserialization-error-crm-extension/18918/4 "2020-02-24T01:23:20Z")

</div>

Hey @PaulAlmond91,

Just an update here. I’ve checked in with our team and we are able to confirm that the URI provided - _[https://tswt.administrateapp.com/beta#/events/events/31823#students](https://tswt.administrateapp.com/beta#/events/events/31823#students)_ is not valid according to **RFC 3986** : [RFC 3986 - Uniform Resource Identifier (URI): Generic Syntax](https://tools.ietf.org/html/rfc3986#section-3.5).

A `#` symbol is reserved for a `fragment` . Any characters that follow a `#` until the end of the URI are considered part of the `fragment` and additional `#` are not allowed. Since the URI provided has more than one `#` , the one that indicates the `fragment` should be left as a `#` and the other one needs to be encoded with `%23`.

Our best guess looking at it is that the `fragment` is “_#students_” and the earlier `#` needs to be encoded with `%23`. Something like this - [https://tswt.administrateapp.com/beta%23/events/events/31823#students](https://tswt.administrateapp.com/beta%23/events/events/31823#students)

Although, we would generally recommend avoiding the use of `#` in a URI other than for `fragments` as it can lead to difficulty in using the URI (due to the encoding requirement) as we are seeing here.

Let me know if this works for you!

---

<div class="post-metadata">

**Author:** ![PaulAlmond91](https://d10pqhm3lwygmk.cloudfront.net/user_avatar/community.hubspot.com/paulalmond91/32/48165_2.png) [@PaulAlmond91](https://community.hubspot.com/u/PaulAlmond91)\
**Post date:** [February 24, 2020, 7:58am UTC](https://community.hubspot.com/t/response-deserialization-error-crm-extension/18918/5 "2020-02-24T07:58:01Z")

</div>

@WendyGoh That makes sense - its something I don’t have too much control but I can use the link without the #students.

Do you have any thoughts regarding:

Another query just as it is happening - I included the allItemLink in hopes that would limit the results displayed and show a view all link at the bottom akin to what is shown here: [Accounts Dashboard | HubSpot](https://developers.hubspot.com/docs/methods/crm-extensions/crm-extensions-overview) (where it says view all 7 tickets)

Thanks

---

<div class="post-metadata">

**Author:** ![WendyGoh](https://d10pqhm3lwygmk.cloudfront.net/user_avatar/community.hubspot.com/wendygoh/32/42320_2.png) [@WendyGoh](https://community.hubspot.com/u/WendyGoh)\
**Post date:** [February 26, 2020, 1:44am UTC](https://community.hubspot.com/t/response-deserialization-error-crm-extension/18918/6 "2020-02-26T01:44:34Z")

</div>

Hey @PaulAlmond91,

This looks to be an unexpected behavior. I would expect it to show ‘_View all 7 tickets_’. In this case, I’ll have to check in with my internal team and I’ll keep you posted here!

---

<div class="post-metadata">

**Author:** ![WendyGoh](https://d10pqhm3lwygmk.cloudfront.net/user_avatar/community.hubspot.com/wendygoh/32/42320_2.png) [@WendyGoh](https://community.hubspot.com/u/WendyGoh)\
**Post date:** [February 27, 2020, 2:34am UTC](https://community.hubspot.com/t/response-deserialization-error-crm-extension/18918/7 "2020-02-27T02:34:08Z")

</div>

Hey @PaulAlmond91,

Just an update here!

The team has recently pushed an update which appears to have resolved the “Response deserialization error” response for other customers and this may possibly resolved the `allItemLink` not displaying issue.

Can you check if you’re still able to reproduce the error now, after the fix was pushed?

---

<div class="post-metadata">

**Author:** ![WendyGoh](https://d10pqhm3lwygmk.cloudfront.net/user_avatar/community.hubspot.com/wendygoh/32/42320_2.png) [@WendyGoh](https://community.hubspot.com/u/WendyGoh)\
**Post date:** [February 28, 2020, 1:08am UTC](https://community.hubspot.com/t/response-deserialization-error-crm-extension/18918/8 "2020-02-28T01:08:20Z")

</div>

Hey @PaulAlmond91,

It looks like the results have `"allItemLink"`, not “`allItemsLink`”. Could you try and see if that fixes it?

---

<div class="post-metadata">

**Author:** ![PaulAlmond91](https://d10pqhm3lwygmk.cloudfront.net/user_avatar/community.hubspot.com/paulalmond91/32/48165_2.png) [@PaulAlmond91](https://community.hubspot.com/u/PaulAlmond91)\
**Post date:** [February 28, 2020, 10:26am UTC](https://community.hubspot.com/t/response-deserialization-error-crm-extension/18918/9 "2020-02-28T10:26:28Z")

</div>

Hi @WendyGoh

That is indeed the error - always a simple answer.

Thanks for your assistance this is now working as i’d hope.
