# How can I get then number of bundles?

**URL:** <https://community.make.com/t/how-can-i-get-then-number-of-bundles/39647>\
**Category:** Questions\
**Tags:** filters\
**Created:** [May 31, 2024, 5:56am UTC](https://community.make.com/t/how-can-i-get-then-number-of-bundles/39647 "2024-05-31T05:56:13Z")\
**Posts on this page:** 10\
**Page:** 1

<div class="post-metadata">

**Author:** ![Claudi](https://avatars.discourse-cdn.com/v4/letter/c/7ab992/32.png) [@Claudi](https://community.make.com/u/Claudi)\
**Post date:** [May 31, 2024, 5:56am UTC](https://community.make.com/t/how-can-i-get-then-number-of-bundles/39647/1 "2024-05-31T05:56:13Z")

</div>

[blueprint (1).json](https://community.make.com/uploads/short-url/8qMbWVUfLtZg6cPJbpzU4wnu7kQ.json) (64.6 KB)  
Hi Team,

I am working on the project attached and I want to get number of bundles by each ID of the conversation but I am a bit lost and I can´t find the way for it. On the below branch I want to get the value of the time, Id and number of bundles for each ID number but I don´t find the way. Any help or idea? Thanks in advance.

---

<div class="post-metadata">

**Author:** ![samliew](https://dub1.discourse-cdn.com/flex013/user_avatar/community.make.com/samliew/32/13327_2.png) [@samliew](https://community.make.com/u/samliew)\
**Post date:** [May 31, 2024, 6:26am UTC](https://community.make.com/t/how-can-i-get-then-number-of-bundles/39647/2 "2024-05-31T06:26:32Z")

</div>

Welcome to the Make community!

Could you share some screenshots of what you’re describing? Also

Please provide the **output** bundles of the modules by running the scenario (or get from the [scenario History tab](https://www.make.com/en/help/scenarios/scenario-execution-history)), then click the white speech bubble on the top-right of each module and select “Download input/output bundles”.

 ![Screenshot_2023-10-06_141025](https://europe1.discourse-cdn.com/flex013/uploads/make/original/3X/2/8/2876156ab3ea5bc9e40bbc0edfb9f025406b7c48.png)

## A.

Save each bundle contents in your text editor as a `bundle.txt` file, and upload it here into this discussion thread.

Uploading them here will look like this:

> module-1-input-bundle.txt (12.3 KB)  
> module-1-output-bundle.txt (12.3 KB)

## B.

If you are unable to upload files on this forum, alternatively you can paste the formatted bundles in this manner:

- Either add three backticks ````` before and after the code, like this:

- Or use the format code button in the editor:  
 ![Screenshot_2023-10-02_191027](https://europe1.discourse-cdn.com/flex013/uploads/make/original/3X/b/4/b485b6572c7a1c438f9b191c54e63d351008304c.png)

Providing the input/output bundles will allow others to _replicate_ what is going on in the scenario even if they do not use the external service.

This will allow others to better assist you. Thanks!

[samliew](https://samliew.com/services) – [request private consultation](https://samliew.com/request-quote?ServiceType=Automation%20Consultation&Referrer=Make)

> Join the unofficial [Make Discord server](https://samliew.com/make-discord-invite) to chat with other makers!

---

<div class="post-metadata">

**Author:** ![Claudi](https://avatars.discourse-cdn.com/v4/letter/c/7ab992/32.png) [@Claudi](https://community.make.com/u/Claudi)\
**Post date:** [May 31, 2024, 6:34am UTC](https://community.make.com/t/how-can-i-get-then-number-of-bundles/39647/3 "2024-05-31T06:34:06Z")

</div>

Sure!!

 ![image](https://europe1.discourse-cdn.com/flex013/uploads/make/original/3X/5/1/5165734b02e687f977bd55627bbeb153504645b8.png)  
Here is my project. I want several things:

1.- Order the inputs on my sheet by dates on the top google sheet.  
2.- On the below I want to get the bundles for each ID order by date too.

Sorry but when I try to download the output I get a pop up with the output but no way for downloading the file.

---

<div class="post-metadata">

**Author:** ![Claudi](https://avatars.discourse-cdn.com/v4/letter/c/7ab992/32.png) [@Claudi](https://community.make.com/u/Claudi)\
**Post date:** [May 31, 2024, 6:38am UTC](https://community.make.com/t/how-can-i-get-then-number-of-bundles/39647/4 "2024-05-31T06:38:41Z")

</div>

![image](https://europe1.discourse-cdn.com/flex013/uploads/make/original/3X/7/a/7a4191306f552ba8314316a4b49b45a15d20b242.png)  
[1\_1.txt](https://community.make.com/uploads/short-url/njZRdPJ4c5cfTbYiZnpCKh8IWyU.txt) (2.4 KB)  
[1\_2.txt](https://community.make.com/uploads/short-url/cyFyEMNmDq6hJMQuNxbUlMlPE1m.txt) (1.5 KB)  
[1\_3.txt](https://community.make.com/uploads/short-url/pxm4tLOHW2cilCD2qnBsWuMlXQp.txt) (1.9 KB)  
These are the outputs for this item. For this item the only thing I need is ordered by date.

---

<div class="post-metadata">

**Author:** ![Claudi](https://avatars.discourse-cdn.com/v4/letter/c/7ab992/32.png) [@Claudi](https://community.make.com/u/Claudi)\
**Post date:** [May 31, 2024, 6:41am UTC](https://community.make.com/t/how-can-i-get-then-number-of-bundles/39647/5 "2024-05-31T06:41:12Z")

</div>

![image](https://europe1.discourse-cdn.com/flex013/uploads/make/original/3X/7/f/7f89eeae11ffa2de506e85a2ec9f82f659f1828b.png)  
[2\_1.txt](https://community.make.com/uploads/short-url/jGb33AZ0sTOapoWsAJJVvHWmd7C.txt) (132 Bytes)  
[2\_2.txt](https://community.make.com/uploads/short-url/3Q8fkfh4TOHWCBHb4WQGG3cX2ym.txt) (132 Bytes)  
[2\_3.txt](https://community.make.com/uploads/short-url/10PCNPSAeRFAv4yCNuE5UBuZ1t7.txt) (132 Bytes)  
For this, I will need to have for each id the number of bundles ordered by date too.

Thanks in advance.

---

<div class="post-metadata">

**Author:** ![Claudi](https://avatars.discourse-cdn.com/v4/letter/c/7ab992/32.png) [@Claudi](https://community.make.com/u/Claudi)\
**Post date:** [May 31, 2024, 6:42am UTC](https://community.make.com/t/how-can-i-get-then-number-of-bundles/39647/6 "2024-05-31T06:42:54Z")

</div>

![image](https://europe1.discourse-cdn.com/flex013/uploads/make/original/3X/6/1/6173e1b29baac37f72954a64373f8dd93dd7bd3a.png)  
[3\_1.txt](https://community.make.com/uploads/short-url/1ATjRH17uDqUiF6carGM184h4Am.txt) (6.4 KB)  
Here u are all. Do you need the output of the google sheets too?

---

<div class="post-metadata">

**Author:** ![samliew](https://dub1.discourse-cdn.com/flex013/user_avatar/community.make.com/samliew/32/13327_2.png) [@samliew](https://community.make.com/u/samliew)\
**Post date:** [May 31, 2024, 8:06am UTC](https://community.make.com/t/how-can-i-get-then-number-of-bundles/39647/7 "2024-05-31T08:06:36Z")

</div>

Welcome to the Make community!

Yes, that is possible. You’ll need an aggregator to convert the bundles into an array, before you can use an Iterator module to sort and split them back up into bundles:

 ![Screenshot_2024-05-31_160544](https://europe1.discourse-cdn.com/flex013/uploads/make/original/3X/7/8/78ffa72109ff8ebd826c959feedfac512a592de7.png)

Give it a go and let us know if you have any issues!

## Module Export

You can **copy** and **paste** this module export into your scenario. This will paste the modules shown in my screenshots above.

1. Copy the JSON code below by clicking the copy button when you mouseover the **top-right** of the code block  
 ![Screenshot_2024-01-17_200117](https://europe1.discourse-cdn.com/flex013/uploads/make/original/3X/2/b/2b1b692880388420db5045bf51ef344e6698a816.png)

2. Enter your scenario editor. Press ESC to close any dialogs. Press CTRLV (paste keyboard shortcut for Windows) to paste directly in the canvas.

3. Click on each imported module and save it for validation. You may be prompted to remap some variables and connections.

> **View Module Export Code**
>
> #### JSON
> 
> ```json
> {
> "subflows": [
> {
> "flow": [
> {
> "id": 1,
> "module": "json:ParseJSON",
> "version": 1,
> "parameters": {
> "type": ""
> },
> "mapper": {
> "json": "[\n {\n \"id\": \"b37b0360-a747-4719-8218-54cc3bcb71f0\",\n \"source\": \"API/Embed\",\n \"sessionId\": \"b37b0360-a747-4719-8218-54cc3bcb71f0\",\n \"memoryType\": \"Buffer Window Memory\",\n \"email\": \"\",\n \"messages\": [\n {\n \"content\": \"Aupi\",\n \"role\": \"user\",\n \"time\": \"2024-05-31T05:36:18.916Z\"\n },\n {\n \"content\": \"Hello! How can I assist you today?\",\n \"role\": \"bot\",\n \"time\": \"2024-05-31T05:36:19.803Z\"\n },\n {\n \"content\": \"que tal lo llevas?\",\n \"role\": \"user\",\n \"time\": \"2024-05-31T05:36:23.489Z\"\n },\n {\n \"content\": \"¡Estoy aquí y listo para ayudarte! ¿En qué puedo asistirte hoy?\",\n \"role\": \"bot\",\n \"time\": \"2024-05-31T05:36:24.970Z\"\n },\n {\n \"content\": \"me puedes dar la prevision del tiempo para este fin de semana en Erandio?\",\n \"role\": \"user\",\n \"time\": \"2024-05-31T05:36:41.723Z\"\n },\n {\n \"content\": \"Aquí tienes la previsión del tiempo para este fin de semana en Erandio:\\n\\n **Sábado:** \\n- **Temperatura:** 19°C (67°F)\\n- **Precipitación:** 40%\\n- **Humedad:** 73%\\n- **Viento:** 18 km/h (11 mph)\\n- **Clima:** Chubascos dispersos\\n\\nSi necesitas más detalles o la previsión para el domingo, házmelo saber.\",\n \"role\": \"bot\",\n \"time\": \"2024-05-31T05:36:47.255Z\",\n \"usedTools\": [\n {\n \"tool\": \"search\",\n \"toolInput\": {\n \"input\": \"previsión del tiempo para este fin de semana en Erandio\"\n },\n \"toolOutput\": \"{\\\"type\\\":\\\"weather_result\\\",\\\"temperature\\\":\\\"67\\\",\\\"unit\\\":\\\"Fahrenheit\\\",\\\"precipitation\\\":\\\"40%\\\",\\\"humidity\\\":\\\"73%\\\",\\\"wind\\\":\\\"11 mph\\\",\\\"location\\\":\\\"Erandio, Spain\\\",\\\"date\\\":\\\"Saturday\\\",\\\"weather\\\":\\\"Scattered showers\\\"}\"\n }\n],\n \"feedback\": \"Perfecto con la tool de Serp AI\"\n },\n {\n \"content\": \"Esta todo correcto, gracias\",\n \"role\": \"user\",\n \"time\": \"2024-05-31T05:37:14.249Z\"\n },\n {\n \"content\": \"¡De nada! Si necesitas algo más, no dudes en decírmelo. ¡Que tengas un buen día!\",\n \"role\": \"bot\",\n \"time\": \"2024-05-31T05:37:15.384Z\"\n }\n ]\n },\n {\n \"id\": \"fb39accf-c648-4c36-8263-4dee58bd675e\",\n \"source\": \"API/Embed\",\n \"sessionId\": \"fb39accf-c648-4c36-8263-4dee58bd675e\",\n \"memoryType\": \"Buffer Window Memory\",\n \"email\": \"\",\n \"messages\": [\n {\n \"content\": \"Buenas de nuevo\",\n \"role\": \"user\",\n \"time\": \"2024-05-31T05:35:31.895Z\"\n },\n {\n \"content\": \"¡Hola! ¿En qué puedo ayudarte hoy?\",\n \"role\": \"bot\",\n \"time\": \"2024-05-31T05:35:32.909Z\"\n },\n {\n \"content\": \"me puedes decir cuanto es 34545367 x 2435?\",\n \"role\": \"user\",\n \"time\": \"2024-05-31T05:35:45.530Z\"\n },\n {\n \"content\": \"El resultado de \\\\( 34545367 \\\\times 2435 \\\\) es 84,117,968,645.\",\n \"role\": \"bot\",\n \"time\": \"2024-05-31T05:35:47.351Z\",\n \"usedTools\": [\n {\n \"tool\": \"calculator\",\n \"toolInput\": {\n \"input\": \"34545367 * 2435\"\n },\n \"toolOutput\": \"84117968645\"\n }\n],\n \"feedback\": \"Buena respuesta con el tool\"\n },\n {\n \"content\": \"gracias\",\n \"role\": \"user\",\n \"time\": \"2024-05-31T05:36:07.466Z\"\n },\n {\n \"content\": \"¡De nada! Si necesitas algo más, no dudes en decírmelo.\",\n \"role\": \"bot\",\n \"time\": \"2024-05-31T05:36:08.288Z\"\n }\n ]\n },\n {\n \"id\": \"da1db21e-c02d-47a8-bf6a-3d81e90b5a97\",\n \"source\": \"API/Embed\",\n \"sessionId\": \"da1db21e-c02d-47a8-bf6a-3d81e90b5a97\",\n \"memoryType\": \"Buffer Window Memory\",\n \"email\": \"\",\n \"messages\": [\n {\n \"content\": \"Hola\",\n \"role\": \"user\",\n \"time\": \"2024-05-31T05:32:06.121Z\"\n },\n {\n \"content\": \"¡Hola! ¿En qué puedo ayudarte hoy?\",\n \"role\": \"bot\",\n \"time\": \"2024-05-31T05:32:07.097Z\"\n },\n {\n \"content\": \"que tal estas hoy?\",\n \"role\": \"user\",\n \"time\": \"2024-05-31T05:32:12.871Z\"\n },\n {\n \"content\": \"¡Gracias por preguntar! Estoy aquí y listo para ayudarte. ¿En qué puedo asistirte hoy?\",\n \"role\": \"bot\",\n \"time\": \"2024-05-31T05:32:13.754Z\"\n },\n {\n \"content\": \"que tiempo va a hacer hoy en Erandio?\",\n \"role\": \"user\",\n \"time\": \"2024-05-31T05:32:24.988Z\"\n },\n {\n \"content\": \"Actualmente, no tengo acceso a información en tiempo real, como el clima. Te recomendaría que consultes una aplicación de clima o un sitio web confiable para obtener la información más actualizada sobre el tiempo en Erandio. ¿Hay algo más en lo que pueda ayudarte?\",\n \"role\": \"bot\",\n \"time\": \"2024-05-31T05:32:26.168Z\",\n \"feedback\": \"La respuesta no ha sido correcta del todo\"\n },\n {\n \"content\": \"de momento no, muchas gracias\",\n \"role\": \"user\",\n \"time\": \"2024-05-31T05:32:37.416Z\"\n },\n {\n \"content\": \"¡De nada! Si necesitas ayuda en el futuro, no dudes en preguntar. ¡Que tengas un buen día!\",\n \"role\": \"bot\",\n \"time\": \"2024-05-31T05:32:38.649Z\",\n \"feedback\": \"\"\n }\n]\n }\n ]"
> },
> "metadata": {
> "designer": {
> "x": 0,
> "y": 150
> },
> "restore": {
> "parameters": {
> "type": {
> "label": "Choose a data structure"
> }
> }
> },
> "parameters": [
> {
> "name": "type",
> "type": "udt",
> "label": "Data structure"
> }
> ],
> "expect": [
> {
> "name": "json",
> "type": "text",
> "label": "JSON string",
> "required": true
> }
> ]
> }
> },
> {
> "id": 11,
> "module": "builtin:BasicAggregator",
> "version": 1,
> "parameters": {
> "feeder": 1
> },
> "mapper": {
> "id": "{{1.id}}",
> "source": "{{1.source}}",
> "sessionId": "{{1.sessionId}}",
> "memoryType": "{{1.memoryType}}",
> "email": "{{1.email}}",
> "messages": "{{1.messages}}"
> },
> "metadata": {
> "designer": {
> "x": 300,
> "y": 150
> },
> "restore": {
> "extra": {
> "feeder": {
> "label": "JSON - Parse JSON [1]"
> },
> "target": {
> "label": "Custom"
> }
> }
> }
> }
> },
> {
> "id": 12,
> "module": "builtin:BasicFeeder",
> "version": 1,
> "parameters": {},
> "mapper": {
> "array": "{{sort(11.array; \"asc\"; \"messages.1.time\")}}"
> },
> "metadata": {
> "designer": {
> "x": 600,
> "y": 150
> },
> "restore": {
> "expect": {
> "array": {
> "mode": "edit"
> }
> }
> },
> "expect": [
> {
> "name": "array",
> "type": "array",
> "label": "Array",
> "mode": "edit",
> "spec": []
> }
> ]
> }
> }
> ]
> }
> ],
> "metadata": {
> "version": 1
> }
> }
> 
> ```

[samliew](https://samliew.com/services) – [request private consultation](https://samliew.com/request-quote?ServiceType=Automation%20Consultation&Referrer=Make)

> Join the unofficial [Make Discord server](https://samliew.com/make-discord-invite) to chat with other makers!

---

<div class="post-metadata">

**Author:** ![Claudi](https://avatars.discourse-cdn.com/v4/letter/c/7ab992/32.png) [@Claudi](https://community.make.com/u/Claudi)\
**Post date:** [May 31, 2024, 8:25am UTC](https://community.make.com/t/how-can-i-get-then-number-of-bundles/39647/8 "2024-05-31T08:25:41Z")

</div>

Thanks a lot for you time!!!

---

<div class="post-metadata">

**Author:** ![alex.newpath](https://dub1.discourse-cdn.com/flex013/user_avatar/community.make.com/alex.newpath/32/84_2.png) [@alex.newpath](https://community.make.com/u/alex.newpath)\
**Post date:** [June 1, 2024, 4:25pm UTC](https://community.make.com/t/how-can-i-get-then-number-of-bundles/39647/9 "2024-06-01T16:25:15Z")

</div>

Can you share what the spreadsheets are you want to generate for both routes? Specifically the data from the ParseJSON where it goes and how it is ordered?

---

<div class="post-metadata">

**Author:** ![Make\_Bot](https://dub1.discourse-cdn.com/flex013/user_avatar/community.make.com/make_bot/32/14661_2.png) [@Make\_Bot](https://community.make.com/u/Make_Bot)\
**Post date:** [August 30, 2024, 4:34pm UTC](https://community.make.com/t/how-can-i-get-then-number-of-bundles/39647/10 "2024-08-30T16:34:02Z")

</div>


