Expose Filtering Endpoint for Bluesky Feed Search Posts
Description
Create a new endpoint in safe-skies-api that proxies requests to Bluesky’s protected app.bsky.feed.searchPosts endpoint. This endpoint will leverage the existing AtprotoAgent to make authenticated requests—authentication is already handled by the authenticateJWT middleware.
Acceptance Criteria
- Endpoint Exposure:
- A new route is created, e.g.,
POST /api/feed/searchPosts, in safe-skies-api.
- Use of AtprotoAgent:
- The endpoint uses the existing
AtprotoAgent to forward requests to Bluesky’s feed search endpoint.
- Parameter Support:
- The endpoint accepts all filtering parameters supported by Bluesky’s API (e.g., keywords, author filters, sort, pagination, etc.).
- Response Handling:
- The response from Bluesky is returned to the client with any required transformations.
- Error Handling:
- Errors from Bluesky (or failures in parameter validation) are caught and returned in an informative manner.
- Security:
- The route is protected by the
authenticateJWT middleware; no additional authentication flow is needed.
Tasks
Expose Filtering Endpoint for Bluesky Feed Search Posts
Description
Create a new endpoint in safe-skies-api that proxies requests to Bluesky’s protected app.bsky.feed.searchPosts endpoint. This endpoint will leverage the existing
AtprotoAgentto make authenticated requests—authentication is already handled by theauthenticateJWTmiddleware.Acceptance Criteria
POST /api/feed/searchPosts, in safe-skies-api.AtprotoAgentto forward requests to Bluesky’s feed search endpoint.authenticateJWTmiddleware; no additional authentication flow is needed.Tasks
POST /api/feed/searchPosts) in safe-skies-api.