Open barakforkids opened 4 weeks ago
I'm not a .net programmer, but if you have the headers correctly you should have access. Did you try hardcoding the base64 code to the header?
Tried menualy hardcoded and code on runtime, both returns 403.
בתאריך יום ו׳, 16 באוג׳ 2024 ב-13:45 מאת astroanu < @.***>:
I'm not a .net programmer, but if you have the headers correctly you should have access. Did you try hardcoding the base64 code to the header?
— Reply to this email directly, view it on GitHub https://github.com/AstronomyAPI/Samples/issues/75#issuecomment-2293276892, or unsubscribe https://github.com/notifications/unsubscribe-auth/ABHRZPFWZYH2L3OVZLXMU3TZRXJ3VAVCNFSM6AAAAABMQWK2BKVHI2DSMVQWIX3LMV43OSLTON2WKQ3PNVWWK3TUHMZDEOJTGI3TMOBZGI . You are receiving this because you authored the thread.Message ID: @.***>
-- בכבוד רב, ברק שקד המסלול הירוק לקידום ברשת www.hamaslul-hayarok.co.il
Could you post the appId you're using to call the API ?
f76bf9d8-8c24-420f-8802-97bd88506fc3
this is how I add the header client.Headers.Add("Authorization", "Basic " + Convert.ToBase64String(System.Text.Encoding.ASCII.GetBytes(ApplicationId + ":" + ApplicationSecret))); *I tried to replace this with hard coded the string after the convert, got the same error
בתאריך יום ו׳, 16 באוג׳ 2024 ב-18:04 מאת astroanu < @.***>:
Could you post the appId you're using to call the API ?
— Reply to this email directly, view it on GitHub https://github.com/AstronomyAPI/Samples/issues/75#issuecomment-2293678332, or unsubscribe https://github.com/notifications/unsubscribe-auth/ABHRZPDWI23PZXCELEOSRBLZRYIHJAVCNFSM6AAAAABMQWK2BKVHI2DSMVQWIX3LMV43OSLTON2WKQ3PNVWWK3TUHMZDEOJTGY3TQMZTGI . You are receiving this because you authored the thread.Message ID: @.***>
-- בכבוד רב, ברק שקד המסלול הירוק לקידום ברשת www.hamaslul-hayarok.co.il
I could not find any requests made using this application ID using .net. I have enabled c# snippet generation in http://demo.astronomyapi.com/. Could you try the example code with your application id and secret. ?
when I use the demo it is working fine only from my webpage it doesn work and get 403 [image: image.png]
בתאריך יום ו׳, 16 באוג׳ 2024 ב-20:04 מאת astroanu < @.***>:
I could not find any requests made using this application ID using .net. I have enabled c# snippet generation in http://demo.astronomyapi.com/. Could you try the example code with your application id and secret. ?
— Reply to this email directly, view it on GitHub https://github.com/AstronomyAPI/Samples/issues/75#issuecomment-2293854844, or unsubscribe https://github.com/notifications/unsubscribe-auth/ABHRZPCP4CTJXS5IIMMP5QLZRYWJTAVCNFSM6AAAAABMQWK2BKVHI2DSMVQWIX3LMV43OSLTON2WKQ3PNVWWK3TUHMZDEOJTHA2TIOBUGQ . You are receiving this because you authored the thread.Message ID: @.***>
-- בכבוד רב, ברק שקד המסלול הירוק לקידום ברשת www.hamaslul-hayarok.co.il
Hi. I've managed to get response from the api now, now when i'm tring to get the moonrise/moonset hour i'm getting error 422 this is the api url i'm using, can you please show how to fix it? https://api.astronomyapi.com/api/v2/bodies/positions/moon?latitude=31.7683&longitude=35.2137&from_date=2024-08-01&to_date=2024-08-31 thank you.
It doesn't have the elevation and time. Check this page for all the "observer request params" https://docs.astronomyapi.com/requests-and-response/observer-parameters
Ah, I see.
בתאריך יום ד׳, 28 באוג׳ 2024 ב-16:33 מאת astroanu < @.***>:
It doesn't have the elevation and time. Check this page for all the "observer request params" https://docs.astronomyapi.com/requests-and-response/observer-parameters
— Reply to this email directly, view it on GitHub https://github.com/AstronomyAPI/Samples/issues/75#issuecomment-2315332758, or unsubscribe https://github.com/notifications/unsubscribe-auth/ABHRZPDZTIWDLTF5XEQRJEDZTXGSHAVCNFSM6AAAAABMQWK2BKVHI2DSMVQWIX3LMV43OSLTON2WKQ3PNVWWK3TUHMZDGMJVGMZTENZVHA . You are receiving this because you authored the thread.Message ID: @.***>
i'm tring to connect from .net web form, thats the header i'm sending, and get 403, what can fix it? client.Headers.Add("Authorization: Basic " + Convert.ToBase64String(System.Text.Encoding.ASCII.GetBytes(ApplicationId + ":" + ApplicationSecret)));