Uh oh!
There was an error while loading.Please reload this page.
- Notifications
You must be signed in to change notification settings - Fork459
Proposal for Http Plugin.#1311
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to ourterms of service andprivacy statement. We’ll occasionally send you account related emails.
Already on GitHub?Sign in to your account
base:dev
Are you sure you want to change the base?
Uh oh!
There was an error while loading.Please reload this page.
Conversation
taooceros commentedAug 6, 2022
Would you please share a sample plugin? I couldn't see how exactly it will be. |
| protected override string Request(JsonRPCRequestModel rpcRequest, CancellationToken token = default) | ||
| { | ||
| HttpRequestMessage requestMessage = new HttpRequestMessage(HttpMethod.Post, url); | ||
| requestMessage.Content = new StringContent(rpcRequest.ToString(), Encoding.UTF8); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others.Learn more.
I have trouble mostly with this part. It only directly use the rpcRequest as payload, which is mostly flow's style. Therefore, the use case can only be a customized http server.
I would like to see a http plugin not only provide the endpoints address, but also translate flow's query to the specific payload (a parser), and translate the response back to flow's standard response.
Uh oh!
There was an error while loading.Please reload this page.
Adding a new type of JsonRPCPlugin that retrieves results from an API endpoint that can talk the same protocol.
Not completely done. Want to configure the Http methods, etc. but wondering if this will be accepted.