(baseUrl: string)
| 31 | /** The one integration that is actually callable: a read and a write against |
| 32 | * the recording upstream. Everything else in the catalog is discovery mass. */ |
| 33 | const notesSpec = (baseUrl: string): string => |
| 34 | JSON.stringify({ |
| 35 | openapi: "3.0.3", |
| 36 | info: { title: "Notes API", version: "1.0.0" }, |
| 37 | servers: [{ url: baseUrl }], |
| 38 | paths: { |
| 39 | "/notes": { |
| 40 | get: { |
| 41 | operationId: "listNotes", |
| 42 | summary: "List every note in the notebook", |
| 43 | responses: { "200": { description: "ok" } }, |
| 44 | }, |
| 45 | post: { |
| 46 | operationId: "createNote", |
| 47 | summary: "Create a note in the notebook", |
| 48 | requestBody: { |
| 49 | required: true, |
| 50 | content: { |
| 51 | "application/json": { |
| 52 | schema: { |
| 53 | type: "object", |
| 54 | properties: { text: { type: "string" } }, |
| 55 | required: ["text"], |
| 56 | }, |
| 57 | }, |
| 58 | }, |
| 59 | }, |
| 60 | responses: { "200": { description: "ok" } }, |
| 61 | }, |
| 62 | }, |
| 63 | }, |
| 64 | }); |
| 65 | |
| 66 | interface RecordedRequest { |
| 67 | readonly method: string; |
no outgoing calls
no test coverage detected