How i can make API call to our external API. I tried to use fetch , but it misses complete cookies list in the request header.
Is there any service already present in Kibana which i can reuse. Trying to make call from src\core\public\chrome\ui\header\header.tsx to external API.
@flash1293
Thanks for quick reply
Atually for other rest api calls in kibana we have multiple cookies in request header
something like:
Cookie:
JSESSIONID=7D1026E51294445448132A0E7F0E7188F5; JSESSIONID=942B9049AA036DF45468B97C077C366E8;
I want to send multiple cookies in case of external API under request header.
when using credentials: 'include' , it just sends a single cookie(first one) as a result api gets failed.
I don't think this is related to Kibana - for this kind of request it's just a CORS request like any other. Please try to make a similar request from within another web app (not hosted on the same host as the external api) - I suspect it will have the same issue.
Apache, Apache Lucene, Apache Hadoop, Hadoop, HDFS and the yellow elephant logo are trademarks of the Apache Software Foundation in the United States and/or other countries.