{"files":{"SKILL.md":"---\nname: treaties-api\ndescription: \"Treaties API skill. Use when working with Treaties for api. Covers 6 endpoints.\"\nversion: 1.0.0\ngenerator: lapsh\n---\n\n# Treaties API\nAPI version: v1\n\n## Auth\nNo authentication required.\n\n## Base URL\nNot specified.\n\n## Setup\n1. No auth setup needed\n2. GET /api/GovernmentOrganisation -- returns all government organisations.\n3. Explore available endpoints below\n\n## Endpoints\n6 endpoints across 1 group. See references/api-spec.lap for full details.\n\n### Api\n| Method | Path | Description |\n|--------|------|-------------|\n| GET | /api/BusinessItem/{id} | Returns business item by ID. |\n| GET | /api/GovernmentOrganisation | Returns all government organisations. |\n| GET | /api/SeriesMembership | Returns all series memberships. |\n| GET | /api/Treaty | Returns a list of treaties. |\n| GET | /api/Treaty/{id} | Returns a treaty by ID. |\n| GET | /api/Treaty/{id}/BusinessItems | Returns business items belonging to the treaty with ID. |\n\n## Common Questions\nMatch user requests to endpoints in references/api-spec.lap. Key patterns:\n- \"Get BusinessItem details?\" -> GET /api/BusinessItem/{id}\n- \"List all GovernmentOrganisation?\" -> GET /api/GovernmentOrganisation\n- \"List all SeriesMembership?\" -> GET /api/SeriesMembership\n- \"List all Treaty?\" -> GET /api/Treaty\n- \"Get Treaty details?\" -> GET /api/Treaty/{id}\n- \"List all BusinessItems?\" -> GET /api/Treaty/{id}/BusinessItems\n\n## Response Tips\n- Check response schemas in references/api-spec.lap for field details\n- Error responses include status codes and descriptions in the spec\n\n## References\n- Full spec: See references/api-spec.lap for complete endpoint details, parameter tables, and response schemas\n\n> Generated from the official API spec by [LAP](https://lap.sh)\n","references/api-spec.lap":"@lap v0.3\n# Machine-readable API spec. Each @endpoint block is one API call.\n@api Treaties API\n@version v1\n@endpoints 6\n@toc api(6)\n\n@endpoint GET /api/BusinessItem/{id}\n@desc Returns business item by ID.\n@required {id: str # Business item with the ID specified}\n@returns(200) {value: map{id: str?, treatyId: str?, stepName: str?, steps: [str]?, itemDate: str(date-time), houses: [map]?, link: str?, sequence: int(int32), treatyUri: str(uri)?, businessItemUri: str(uri)?, houseUri: str(uri)?, houseName: str?, procedureStepUri: str(uri)?, houseId: str?, procedureStepId: str?, workpackageProcedureUri: str(uri)?}, links: [map]?} # The requested business item\n@errors {400: Bad Request, 404: If the item doesn't exist}\n\n@endpoint GET /api/GovernmentOrganisation\n@desc Returns all government organisations.\n@returns(200) {items: [map]?, totalResults: int(int32), itemsPerPage: int(int32), links: [map]?} # OK\n\n@endpoint GET /api/SeriesMembership\n@desc Returns all series memberships.\n@returns(200) {items: [map]?, totalResults: int(int32), itemsPerPage: int(int32), links: [map]?} # OK\n\n@endpoint GET /api/Treaty\n@desc Returns a list of treaties.\n@optional {SearchText: str, GovernmentOrganisationId: int(int32), Series: str, ParliamentaryProcess: str, DebateScheduled: bool, MotionsTabledAboutATreaty: bool, CommitteeRaisedConcerns: bool, House: str, Skip: int(int32), Take: int(int32)}\n@returns(200) {items: [map]?, totalResults: int(int32), itemsPerPage: int(int32), links: [map]?} # A list of treaties\n@errors {400: Bad Request}\n\n@endpoint GET /api/Treaty/{id}\n@desc Returns a treaty by ID.\n@required {id: str # Treaty with ID specified}\n@returns(200) {value: map{id: str?, name: str?, uri: str(uri)?, commandPaperPrefix: str?, commandPaperNumber: int(int32)?, commonsLayingDate: str(date-time)?, lordsLayingDate: str(date-time)?, webLink: str(uri)?, treatySeriesMembership: map{seriesMembershipType: str, uri: str(uri)?, citation: str?}, leadDepartment: map{id: int(int32), name: str?}, layingBodyDepartment: map{id: int(int32), name: str?}, parliamentaryConclusion: str, debateScheduled: str?, broughtToAttentionDate: str(date-time)?, signedDate: str(date-time)?, laidDate: str(date-time)?, pertinentDate: str(date-time)?, workpackageId: str?}, links: [map]?} # Details of the requested treaty\n@errors {400: Bad Request, 404: If the treaty can't be found}\n\n@endpoint GET /api/Treaty/{id}/BusinessItems\n@desc Returns business items belonging to the treaty with ID.\n@required {id: str # Business items belonging to treaty with the ID specified}\n@returns(200) {items: [map]?, totalResults: int(int32), itemsPerPage: int(int32), links: [map]?} # The business items for the requested treaty\n@errors {400: Bad Request, 404: If the treaty cannot be found}\n\n@end\n"}}