openapi: 3.2.0 info: title: Playground Posts API version: 1.0.0 description: Zero-config per-identity sandboxed mock REST API with relational filtering, dynamic sorting, and network simulation. servers: - url: http://playground-api-backend.vercel.app description: Default Server tags: - name: Posts paths: /api/v1/posts: get: summary: Retrieve a paginated list of posts. parameters: - name: q in: query required: false description: Full-text search query term across title, body, etc. schema: type: string - name: user_id in: query required: false description: Filter posts by author user ID (e.g. user_id=1). schema: type: integer - name: page in: query required: false description: Page number (1-indexed, default 1). schema: type: integer - name: limit in: query required: false description: Number of records per page (default 10, max 200). schema: type: integer - name: _sort in: query required: false description: Field name to sort results by (e.g. title, id, user_id). schema: type: string - name: _order in: query required: false description: 'Sort direction: asc (default) or desc.' schema: type: string responses: '200': description: Successful Operation content: application/json: example: data: - id: local-b2c3d4e5-f6a7-8901-bcde-f12345678901 user_id: 1 title: sunt aut facere repellat provident occaecati excepturi optio reprehenderit _sandbox: created - id: 1 user_id: 1 title: sunt aut facere repellat provident occaecati excepturi optio reprehenderit body: quia et suscipit suscipit recusandae consequuntur expedita et cum reprehenderit molestiae ut ut quas totam nostrum rerum est autem sunt rem eveniet architecto pagination: page: 1 limit: 10 total: 101 totalPages: 11 hasNextPage: true hasPrevPage: false tags: - Posts operationId: getApiV1Posts x-operation-id-source: derived post: summary: Create a new session sandbox post record. parameters: - name: user_id in: body required: false description: Author user ID. schema: type: integer - name: title in: body required: false description: Post title. schema: type: string - name: body in: body required: false description: Post body text content. schema: type: string responses: '200': description: Successful Operation content: application/json: example: id: local-b2c3d4e5-f6a7-8901-bcde-f12345678901 user_id: 1 title: sunt aut facere repellat provident occaecati excepturi optio reprehenderit body: quia et suscipit suscipit recusandae consequuntur expedita et cum reprehenderit molestiae ut ut quas totam nostrum rerum est autem sunt rem eveniet architecto _sandbox: created requestBody: required: true content: application/json: example: user_id: 1 title: sunt aut facere repellat provident occaecati excepturi optio reprehenderit body: quia et suscipit suscipit recusandae consequuntur expedita et cum reprehenderit molestiae ut ut quas totam nostrum rerum est autem sunt rem eveniet architecto tags: - Posts operationId: postApiV1Posts x-operation-id-source: derived /api/v1/posts/{id}: get: summary: Retrieve a single post by ID. parameters: - name: id in: path required: true description: Post ID (e.g. 1 for global post or local- for sandbox post). schema: type: integer responses: '200': description: Successful Operation content: application/json: example: id: 1 user_id: 1 title: sunt aut facere repellat provident occaecati excepturi optio reprehenderit body: quia et suscipit suscipit recusandae consequuntur expedita et cum reprehenderit molestiae ut ut quas totam nostrum rerum est autem sunt rem eveniet architecto tags: - Posts operationId: getApiV1PostsById x-operation-id-source: derived put: summary: Replace an existing post record in the session overlay. parameters: - name: id in: path required: true description: Post ID to update (e.g. 1 or local-). schema: type: integer responses: '200': description: Successful Operation content: application/json: example: id: 1 user_id: 1 title: sunt aut facere repellat provident occaecati excepturi optio reprehenderit (Updated) body: quia et suscipit suscipit recusandae consequuntur expedita et cum reprehenderit molestiae ut ut quas totam nostrum rerum est autem sunt rem eveniet architecto _sandbox: updated requestBody: required: true content: application/json: example: user_id: 1 title: sunt aut facere repellat provident occaecati excepturi optio reprehenderit (Updated) body: quia et suscipit suscipit recusandae consequuntur expedita et cum reprehenderit molestiae ut ut quas totam nostrum rerum est autem sunt rem eveniet architecto tags: - Posts operationId: putApiV1PostsById x-operation-id-source: derived patch: summary: Partially update specific fields of a post record in the session overlay parameters: - name: id in: path required: true description: Post ID to patch (e.g. 1 or local-). schema: type: integer responses: '200': description: Successful Operation content: application/json: example: id: 1 user_id: 1 title: sunt aut facere repellat provident occaecati excepturi optio reprehenderit (Updated) body: quia et suscipit suscipit recusandae consequuntur expedita et cum reprehenderit molestiae ut ut quas totam nostrum rerum est autem sunt rem eveniet architecto _sandbox: updated requestBody: required: true content: application/json: example: title: sunt aut facere repellat provident occaecati excepturi optio reprehenderit (Updated) tags: - Posts operationId: patchApiV1PostsById x-operation-id-source: derived delete: summary: Remove a post record from the requesting session view. parameters: - name: id in: path required: true description: Post ID to delete (e.g. 1 or local-). schema: type: integer responses: '200': description: Successful Operation content: application/json: example: message: Resource 'posts' with id '1' deleted successfully from sandbox overlay id: 1 resource: posts tags: - Posts operationId: deleteApiV1PostsById x-operation-id-source: derived