# Include raw in json request response

**URL:** https://meta.discourse.org/t/include-raw-in-json-request-response/60963
**Category:** Development
**Created:** [April 14, 2017, 3:54am UTC](https://meta.discourse.org/t/include-raw-in-json-request-response/60963 "2017-04-14T03:54:01Z")
**Posts on this page:** 4
**Page:** 1

<div class="post-metadata">

### Author: ![adam\_beers](https://avatars.discourse-cdn.com/v4/letter/a/97f17d/32.png) [@adam\_beers](https://meta.discourse.org/u/adam_beers)
#### Post date: [April 14, 2017, 3:54am UTC](https://meta.discourse.org/t/include-raw-in-json-request-response/60963/1 "2017-04-14T03:54:01Z")

</div>

Is there a way to include the raw as well as the cooked data for a search.json and user\_actions.json request?

The “excerpt” in the response as urls, like the “cooked” entry for other responses. Wanted to have the raw data included. When getting a topic “115.json,” if you include the “include\_raw=true” in the request it will supply the raw as well in the response. Trying to find a similar config in the search.json and user\_actions.json requests.

Here is an example of a request to [example.com/user\_actions.json?username=user1234&filter=5](http://example.com/user_actions.json?username=user1234&filter=5) As seen, the excerpt is “cooked” and the title is raw. I would like the raw excerpt.

```
   "user_actions": [{
		"action_type": 5,
		"created_at": "2017-03-27T02:00:17.757Z",
		"excerpt": "<img src=\"//www.example.com/images/emoji/emoji_one/grinning.png?v=3\" title=\":grinning:\" class=\"emoji\" alt=\":grinning:\"> Reply with emoji face",
		"avatar_template": "/user_avatar/wwjd.example.com/user1234/{size}/57_1.png",
		"acting_avatar_template": "/user_avatar/wwjd.example.com/user1234/{size}/57_1.png",
		"slug": "this-is-an-emoji-post",
		"topic_id": 137,
		"target_user_id": 67,
		"target_name": null,
		"target_username": "user1234",
		"post_number": 3,
		"post_id": 185,
		"reply_to_post_number": null,
		"username": "user1234",
		"name": null,
		"user_id": 67,
		"acting_username": "user1234",
		"acting_name": null,
		"acting_user_id": 67,
		"title": "😀 This is an emoji post",
		"deleted": false,
		"hidden": false,
		"post_type": 1,
		"action_code": null,
		"category_id": 1,
		"closed": false,
		"archived": false
	}

```

---

<div class="post-metadata">

### Author: ![adam\_beers](https://avatars.discourse-cdn.com/v4/letter/a/97f17d/32.png) [@adam\_beers](https://meta.discourse.org/u/adam_beers)
#### Post date: [April 24, 2017, 10:49pm UTC](https://meta.discourse.org/t/include-raw-in-json-request-response/60963/2 "2017-04-24T22:49:40Z")

</div>

Any ideas? If I knew how to change it, I would do it myself and submit the changes for review, but I’m not familiar with this programming language.

Is there someone I could talk to about how to go about changing it?

---

<div class="post-metadata">

### Author: ![Mittineague](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/mittineague/32/114259_2.png) [@Mittineague](https://meta.discourse.org/u/Mittineague)
#### Post date: [April 24, 2017, 11:30pm UTC](https://meta.discourse.org/t/include-raw-in-json-request-response/60963/3 "2017-04-24T23:30:49Z")

</div>

I don’t think there are raw excerpts.  
There are raw posts.  
I don’t know of any way to get JSON from more than one in a single request as things are now.  
But this should be doable in a plugin that could pull the data and output it as JSON

---

<div class="post-metadata">

### Author: ![adam\_beers](https://avatars.discourse-cdn.com/v4/letter/a/97f17d/32.png) [@adam\_beers](https://meta.discourse.org/u/adam_beers)
#### Post date: [April 25, 2017, 2:18am UTC](https://meta.discourse.org/t/include-raw-in-json-request-response/60963/4 "2017-04-25T02:18:55Z")

</div>

If I do a user\_actions.json?filter=5&username=bob123, then I will get all replies that bob123 has done. Which could be a large number, but it gives all of them back. It is getting more than one item, as you are talking about. I only showed one item for space limits.
