# Sending data to new Data Stream with Elastic Agent

**URL:** https://discuss.elastic.co/t/sending-data-to-new-data-stream-with-elastic-agent/353926
**Category:** Elastic Agent
**Created:** [February 22, 2024, 9:18pm UTC](https://discuss.elastic.co/t/sending-data-to-new-data-stream-with-elastic-agent/353926 "2024-02-22T21:18:11Z")
**Posts on this page:** 1
**Showing post:** 10

<div class="post-metadata">

### Author: ![stephenb](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/stephenb/32/40856_2.png) [@stephenb](https://discuss.elastic.co/u/stephenb)
#### Post date: [February 23, 2024, 1:27am UTC](https://discuss.elastic.co/t/sending-data-to-new-data-stream-with-elastic-agent/353926/10 "2024-02-23T01:27:43Z")

</div>

Well test it out... Let us know...

Are you using standalone or fleet managed?

It's not really the approach I'm taking... What I gave you is a manageable scalable approach... Which can literally be set up in about 5 minutes and then start testing...

You can test the ingest pipeline using the \_simulate API too...

I find debugging the agent.yml much harder than just the custom pipelines...

That said, there's always more than one way to do things..

I think it may be possible but your syntax is most likely not correct...

I don't know what the correct syntax would be off hand

I do think there's a conditional pipeline but it needs to go with an index or something to that effect. What affect that has on the Data Stream Name I am not sure...

It's using filebeat somewhat under the covers....

> [@Conditional index + pipeline in output?](https://discuss.elastic.co/t/conditional-index-pipeline-in-output/138163):
>
> I noticed [here](https://discuss.elastic.co/t/conditional-filebeat-output-based-on-document-type/117233) that you can do conditional selection of indices in the output. I was trying to carry that over to also use a specific pipeline when sending to that index as well. Here's what I have; output.elasticsearch: hosts: ["http://192.168.1.199:9206"] index: "filebeat-%{[beat.version]}-%{+yyyy.MM}" indices: - index: "filebeat-pihole-%{[beat.version]}-%{+yyyy.MM}" pipeline: pihole-logging when.contains: message: "dnsmasq" I am getting this Exiting: error l…

Maybe look at this.

---

_[View the full topic](https://discuss.elastic.co/t/sending-data-to-new-data-stream-with-elastic-agent/353926)._
