webwrite returns error 405, how to find its detailed cause?

2 次查看(过去 30 天)
I am trying to get certain graphiql working, but am getting 405 error without any detailed error description.
url = 'https://rata.digitraffic.fi/api/v2/graphql/graphiql';
query = '{ currentlyRunningTrains { trainNumber }}';
options = weboptions('KeyName','Accept-Encoding','KeyValue','gzip');
res = webwrite(url, query, options);
Is it possible to find what is the exact cause for this HTTP 405 error?
P.S. is there any way to properly add
Accept-Encoding: gzip
field into weboptions?

回答(0 个)

产品


版本

R2020a

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by