Implement GET /images #15

Closed
opened 2024-01-03 11:46:51 +00:00 by bizcochito · 2 comments
Owner

Implement the random image generator

one idea I have is

GET /images?status=avaliable&limit=1

The response:
[
{
_id: "wjendkjewndkjew",
url: 2example.booru.moe/status/3974238098437297843",
status: avaliable,
tags: [sleeping, 2girl]
}
]

The content being a list of 1, with the inside equivalent of GET /images/wjendkjewndkjew in this case.

the queryparams by default of our implementation being GET /images?limit=0&page=1 that being no limit and being on page 1 by default.

I would suggest also changin the limit on default to make pagination too. But dunno, out of scope of this issue

Implement the random image generator one idea I have is GET /images?status=avaliable&limit=1 The response: [ { _id: "wjendkjewndkjew", url: 2example.booru.moe/status/3974238098437297843", status: avaliable, tags: [sleeping, 2girl] } ] The content being a list of 1, with the inside equivalent of GET /images/wjendkjewndkjew in this case. the queryparams by default of our implementation being GET /images?limit=0&page=1 that being no limit and being on page 1 by default. I would suggest also changin the limit on default to make pagination too. But dunno, out of scope of this issue
bizcochito added this to the (deleted) project 2024-01-03 11:47:14 +00:00
Owner

We will not add the page query param, and we'll add status to filter documents. This is now documented in the README.md file

We will not add the `page` query param, and we'll add `status` to filter documents. This is now documented in the README.md file
Suguivy reopened this issue 2024-01-06 12:37:21 +00:00
Suguivy changed title from Implement GET /images random to Implement GET /images 2024-01-06 12:43:44 +00:00
Owner

Implemented on #20

Implemented on #20
Sign in to join this conversation.
No Label
No Milestone
No project
No Assignees
2 Participants
Notifications
Due Date
The due date is invalid or out of range. Please use the format 'yyyy-mm-dd'.

No due date set.

Dependencies

No dependencies set.

Reference: fedi-image-bot/bot-api#15
No description provided.