Bug 38745 - Add a proof of concept JSON-RPC driven endpoint for RPC style calls that don't fit REST ideals
Summary: Add a proof of concept JSON-RPC driven endpoint for RPC style calls that don'...
Status: NEW
Alias: None
Product: Koha
Classification: Unclassified
Component: Web services (show other bugs)
Version: Main
Hardware: All All
: P5 - low enhancement
Assignee: Bugs List
QA Contact: Testopia
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2024-12-18 17:06 UTC by Martin Renvoize (ashimema)
Modified: 2025-01-29 00:42 UTC (History)
2 users (show)

See Also:
Change sponsored?: ---
Patch complexity: ---
Documentation contact:
Documentation submission:
Text to go in the release notes:
Version(s) released in:
Circulation function:


Attachments
Bug 38745: Add RPC Router (2.57 KB, patch)
2024-12-20 13:44 UTC, Martin Renvoize (ashimema)
Details | Diff | Splinter Review
Bug 38745: Start adding a populate_empty_callnumbers RPC method (3.36 KB, patch)
2024-12-20 13:44 UTC, Martin Renvoize (ashimema)
Details | Diff | Splinter Review

Note You need to log in before you can comment on or make changes to this bug.
Description Martin Renvoize (ashimema) 2024-12-18 17:06:44 UTC
We have a few places where RPC style calls to perform various actions makes sense.. thinking 'bulk' actions and also 'test' actions for things like the sftp connection checks

I propose a distinct /rpc endpoint with a basic router built into the endpoint and oneOf being used to specify using the existing OpenAPI specifications.
Comment 1 Martin Renvoize (ashimema) 2024-12-20 13:44:41 UTC
Created attachment 175843 [details] [review]
Bug 38745: Add RPC Router

This patch add an RPC controller under the REST API to act as a router
for JSON-RPC 2.0 syle requests.
Comment 2 Martin Renvoize (ashimema) 2024-12-20 13:44:43 UTC
Created attachment 175844 [details] [review]
Bug 38745: Start adding a populate_empty_callnumbers RPC method

This patch takes the populate_empty_callnumbers method as proposed on
bug 38226 and modifies it for json-rpc expectations.
Comment 3 Martin Renvoize (ashimema) 2024-12-20 13:45:12 UTC
Very much a proof of concept for code and not usable yet