Dev news: Launching API version 2 (also v1 deprecation notice) | Last updated 2021-01-17

Status
Not open for further replies.
Active member
Joined
Jul 13, 2020
Messages
333
I love this site but Im broke and adding fuel to the fire I play 3 gacha games
 
Group Leader
Joined
Mar 9, 2018
Messages
354
v2 works great, thank You. Random question: is method for generating hash something usable for checking if chapter was correctly downloaded? (if yes, what function it is)?
Thanks in advance.
 
Double-page supporter
Joined
Jan 17, 2018
Messages
3,198
@Irian According to discord, chapter hash is just a token (url/data/hash/image). It's updated on edit upload, so you could use it for version control.
Recent uploads have sha256 as filenames, use them to verify the checksum when available.
 
Joined
Jan 31, 2019
Messages
36
@FayeABrown you need to include your mangadex_session in the header as a cookie. You can get your mangadex_session from logged-in cookies.

Code:
curl -H 'Content-Type: application/json' -H 'User-Agent: Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/81.0.4044.138 Safari/537.36' -H 'Cookie: mangadex_session=xxxx-xxxx-xxxx' 'https://mangadex.org/api/v2/user/me'
 
Joined
Apr 25, 2020
Messages
12
I noticed that the chapter request response does not contain a Boolean for whether the chapter is long strip or not which is very crucial.
 
Custom title
Staff
Developer
Joined
Jan 19, 2018
Messages
2,475
Well, I kind of fucked this announcement up. I should've expected I was going to make breaking changes to v2 still and said it was like a release candidate or something. I'm sorry about this.

There's two breaking changes I'd like to make: the simple group entities with chapters lists and the way the read param works for markers (namely, moving it from the query to the body, I don't know what I was thinking there). Hopefully not too many people have already made their changes and forgotten about them so I can get away with not having to make like a /api/v2.1 already.

Hoping to push changes soon, me and rdn haven't been around at the same time these couple of days.
 
Joined
Dec 30, 2019
Messages
5
If you're taking requests on improvements to the API, I would LOVE to see some type of filter support on chapters. Popular titles can have a thousand+ chapters and I'm guessing many of the API chapter requests are essentially looking for "I need the IDs for new English chapters since our last check" which is usually only a handful (or no) chapters.

So being able to filter what chapters are returned like:
Code:
/api/v2/manga/{id}/chapters?language=gb&timestamp[gt]=1604876129
or
Code:
/api/v2/manga/{id}/chapters?language=gb&timestamp=gt:1604876129

would save both parties on transferring completely unnecessary chapter data.
 
Joined
Feb 6, 2020
Messages
3
@Teasday If possible, if you're going to add searching to the API I would love to see a parameter to exclude, include, or only include hentai, much like the current hide/view/view only dropdown.
 
Active member
Joined
Apr 18, 2019
Messages
264
I don't know if I'm posting this in the right thread but will we be able to perform searches with the original Japanese titles? Kinda tired of going to MU or whatever and search for the romanized title first.
 
is a Reindeer
VIP
Joined
Jan 24, 2018
Messages
3,231
@go-2-sleep you already can search by japanese titles on mangadex with the search bar though...?
everything in a manga's alt title section is a search term for that manga
 
Active member
Joined
Apr 18, 2019
Messages
264
@Plykiya the fuck? It literally never worked for me before, that's why I asked lmao
Or maybe I was thinking about searching authors Japanese names? Dunno
 
Custom title
Staff
Developer
Joined
Jan 19, 2018
Messages
2,475
2020-11-10
- [Breaking] Changed the
Code:
{ id: "name" }
groups map in chapter listings to an array of simple group entities
Code:
[ { id, name } ]
so that it's in line with the rest of the api
- [Breaking] Moved the
Code:
read
parameter in POST /user/{id}/marker from the query to the body
- Fixed
Code:
lastChapter
always returning null in the manga endpoint
- Added
Code:
uploader
user ID and
Code:
views
to chapter entities
- Added a short explanation about authentication to the
Code:
description
field in the index
- Added /relations to describe the available manga relation types
- Added /follows to describe the available follow types (consider this temporary, we may rework the endpoint)
 
Custom title
Staff
Developer
Joined
Jan 19, 2018
Messages
2,475
And yes I'll be marking the date in my local time so no jokes about the updates being in the future allowed
 
Custom title
Staff
Developer
Joined
Jan 19, 2018
Messages
2,475
@nonindustrial Duly noted, I'd like to include something like that as well. I'm still going to have to figure out what I can get away with when it comes to optimizing queries without breaking the damn site.
 
Joined
Feb 10, 2018
Messages
1
Will there will be a change later in
Code:
/api/v2/user/{id}/followed-manga
to accommodate viewing a person's public/friends MDList in the pipes?
 
Status
Not open for further replies.

Users who are viewing this thread

Top