Repository navigation
Support native HTTP services in apply and service run - #112
Merged
Merged
Conversation
esparig
requested review from
SergioLangaritaBenitez
and
a balanced review from Copilot
December 1, 2026 10:49
There was a problem hiding this comment.
🟡 Changes recommended
Raw file requests omit Content-Length and use chunked transfer, causing the documented AnyDoc example to fail with HTTP 411; the file size must be propagated and covered by a regression test.
1 open issue
What changed in this PR
Adds native HTTP service support to the CLI’s FDL loading and synchronous invocation paths.
Changes:
- Allows HTTP-mode FDLs to omit a script.
- Adds
service run --rawto bypass base64 processing for requests and responses. - Updates OSCAR API dependencies, adds regression tests, and documents an AnyDoc PDF invocation.
| File | Description |
|---|---|
README.md |
Documents --raw and the AnyDoc PDF example. |
pkg/service/service.go |
Allows scriptless HTTP-mode service definitions. |
pkg/service/service_test.go |
Tests loading an HTTP service without a script. |
go.sum |
Updates checksums for the OSCAR dependency change. |
go.mod |
Updates OSCAR API types and indirect dependencies. |
cmd/service_run.go |
Implements raw input/output and excludes simultaneous output decoding. |
cmd/service_run_test.go |
Tests binary input and preservation of base64-looking response text. |
Review effort: Balanced
| } | ||
| // Make the request | ||
| resBody, err := service.RunService(conf.Oscar[cluster], args[0], token, endpoint, reader, header) | ||
| resBody, err := service.RunService(conf.Oscar[cluster], args[0], token, endpoint, inputReader, header) |
Member
Author
There was a problem hiding this comment.
--raw -f now sends the correct Content-Length for regular files while still streaming the request body. I updated the regression test to return HTTP 411 when the header is missing. The full Go test suite passes, and I verified locally that the documented CLI command workds with a synchronous-http service (PDF conversion to Markdown using AnyDoc).
SergioLangaritaBenitez
approved these changes
Dec 1, 2026
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.

Support FDLs with
synchronous.mode: httpand an optional user script. Addservice run --rawto send native request bytes and preserve response bytes, including text that happens to be valid base64. The README includes an AnyDoc PDF example.Uses the OSCAR API types from grycap/oscar#730. Adds regression tests for scriptless HTTP services and binary invocations.