Setting Stream Name in CURL Call and Query Token Error

TLDR TiF asked how to set a stream name in a JSON CURL call and encountered a token error when sending a search query. Prabhat provided advice including the limit of APIs on the cloud service.

Photo of TiF
TiF
Wed, 11 Oct 2023 16:51:52 UTC

sorry for the lame question, how can I set the stream name in CURL call? in json the {"stream": "name ... isn't seems to work

Photo of Prabhat
Prabhat
Wed, 11 Oct 2023 16:54:10 UTC

Photo of Prabhat
Prabhat
Wed, 11 Oct 2023 16:54:18 UTC

Just change the URL

Photo of TiF
TiF
Wed, 11 Oct 2023 17:19:55 UTC

ahh so. I'm mental

Photo of Prabhat
Prabhat
Wed, 11 Oct 2023 17:29:51 UTC

We did not specify that. We should add it

Photo of TiF
TiF
Wed, 11 Oct 2023 18:57:15 UTC

Can you help me? I send search query of this: ```URL (working fine with ingesting, change the search) "" The object sended thru JSON object(stdClass)#84 (2) { ["query"]=> object(stdClass)#83 (7) { ["sql"]=> string(26) "SELECT * FROM "newVisitor"" ["start_time"]=> int(1674789786006000) ["end_time"]=> int(1674789786006000) ["from"]=> int(0) ["size"]=> int(0) ["track_total_hits"]=> bool(false) ["sql_mode"]=> string(7) "context" } ["aggs"]=> object(stdClass)#85 (1) { ["agg1"]=> string(101) "SELECT histogram(_timestamp, "5 minute") AS key, COUNT(*) AS num FROM query GROUP BY key ORDER BY key" } } "{\"Error\":\"Authentication failed - invalid token: token contains an invalid number of segments\"}"```

Photo of Prabhat
Prabhat
Wed, 11 Oct 2023 19:10:03 UTC

only ingestion APIs are currently available on cloud service. We are working on enabling rest of the APis on cloud service. If you intend to call other APIs you will need to use the self-hosted OpenObserve for now

Photo of TiF
TiF
Wed, 11 Oct 2023 19:11:09 UTC

Ahh, okay, understand.