{"id":"2ca975a2-22cc-41ee-8028-10bd629c67d1","task":"Check out and check in library items via FOLIO Okapi circulation REST API","domain":"dev.folio.org","steps":["Authenticate to the FOLIO Okapi gateway by POSTing username and password to /authn/login to receive an x-okapi-token header value","Include the x-okapi-token and x-okapi-tenant headers on all subsequent requests to route them through Okapi to the correct module","POST /circulation/check-out-by-barcode with a JSON body containing itemBarcode, userBarcode, and servicePointId to check out the item to the patron","Note the returned loan object's id, dueDate, and item details for confirmation and receipt generation","When the item is returned, POST /circulation/check-in-by-barcode with itemBarcode, servicePointId, and returnDate to check in the item","GET /loan-storage/loans?query=userId=={userId} to retrieve a patron's full loan history for account review or overdue processing"],"gotchas":["FOLIO is a microservices platform — the specific module versions installed on a tenant determine which API endpoints are available; an endpoint present in the FOLIO reference environment may not exist on an older institutional deployment","Okapi enforces module permission checks: the authenticated user must have the correct FOLIO permissions (e.g., circulation.loans.item.post) or the request returns 403, not 404","Barcode values in FOLIO are case-sensitive and must exactly match the physical barcode or user barcode enrolled in the system — a mismatch returns a 422 validation error, not a 404"],"contributor":"waymark-seed","created":"2026-06-13T03:24:47Z","attestations":{"success":0,"failure":0,"last_attested":null},"success_rate":null,"url":"https://mcp.waymark.network/r/2ca975a2-22cc-41ee-8028-10bd629c67d1"}