jlewi / foyle

Foyle is a copilot to help developers deploy and operate their applications.
https://foyle.io
Apache License 2.0
110 stars 10 forks source link

fix: Correct API endpoint and adjust localhost configuration (Resolves #346) #349

Open IndySeh opened 1 day ago

IndySeh commented 1 day ago

Title

fix: Correct API endpoint and adjust localhost configuration (Resolves #346)

Description:

This pull request addresses the following issues related to the API call and local development setup: • API Endpoint Fix: Updated the endpoint path from foyle.logs.SessionsService/GetSession to api/GetSession for proper routing. • jq Syntax Correction: Added a period (.) after jq to ensure JSON output is parsed and displayed correctly. • Protocol Adjustment: Replaced https:// with http:// for localhost to avoid unnecessary SSL complications during local testing.

Before

CONTEXTID=01J7S3QZMS5F742JFPWZDCTVRG
curl -s -X POST https://localhost:8877/foyle.logs.SessionsService/GetSession -H "Content-Type: application/json" -d "{\"contextId\": \"${CONTEXTID}\"}" | jq.

After

CONTEXTID=01J7S3QZMS5F742JFPWZDCTVRG
curl -s -X POST http://localhost:8877/api/GetSession -H "Content-Type: application/json" -d "{\"contextId\": \"${CONTEXTID}\"}" | jq .

Closes Issue: #346

netlify[bot] commented 1 day ago

Deploy Preview for foyle ready!

Name Link
Latest commit 7b5e41d0bc9ee05055a000cee79cd1b172d22af6
Latest deploy log https://app.netlify.com/sites/foyle/deploys/67440b24f7f43500094621b0
Deploy Preview https://deploy-preview-349--foyle.netlify.app
Preview on mobile
Toggle QR Code...

QR Code

Use your smartphone camera to open QR code link.

To edit notification comments on pull requests, go to your Netlify site configuration.

jlewi commented 1 day ago

Thank you so much for this; one minor suggestion.

IndySeh commented 1 day ago

Thanks for pointing that out! I’ll update the code