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

Status
Not open for further replies.
Joined
Oct 16, 2019
Messages
15
@ohknow ah you're right. I misread the part about chapter listing.

but I can now at least roll out my own server for an optimized chapter reading on my region. It's painfully slow here from southeast asia.
 
Joined
Apr 25, 2020
Messages
12
When launching new apis, please keep the previous versions functional for a certain time in order for third parties to migrate without issues.
 
Dex-chan lover
Joined
Jun 2, 2018
Messages
10,302
so basically tl;dr = tech stuff upgrade, techies please take a look, non-techies please carry on with your usual boob appreciation sessions
 
is a Reindeer
VIP
Joined
Jan 24, 2018
Messages
3,231
@Hassico that's what this is lol
api v1 is still functional and a warning for people to migrate
 
Member
Joined
Nov 12, 2018
Messages
298
Anyone that is part of MD@Home from Europe (Balkan more exactly) can guesstimate how much (internet) data does it use per month?
I moved to different apartment and seems that I can reliably keep 80/40 at times when 40/20 Mbps was great in old apartment (it's around 100-150/45 during a night, that was never an issue). Having 80+/40 around 20-21 is fucking amazing feeling. I have some quazy-datacap where after I reach 1TiB threshold, my connection is pretty much dead (1/1Mbps) in 18-23 part of each day till next month but is otherwise unlimited.
 
Joined
May 27, 2020
Messages
4
Any reason as to why groups in a chapter obj are returning a list?

Code:
"groups": [
  506
],

is there a situation where a chapter might have 2 groups? Its a trivial fix from dev side, but at the same time why not just return an int instead of a list...
Might have to do with the previous version having a group_id, group_id_2 and group_id_3 ??
 
Joined
May 27, 2020
Messages
4
@Halo

thanks for the quick reply :)
I shall account for this in my project, would this simply mean that x groups worked/contributed to the chapter then?
 
VIP
Joined
Jan 21, 2018
Messages
854
@katarushisu You can tag a max of 3 groups on a chapter. On the chapter endpoint, 3 groups would look like this https://mangadex.org/api/v2/chapter/946329
And on the title endpoint it would look like this
Code:
{"id":946329,"hash":"277f10071e986d6c92c1dd222e1c19ab","mangaId":32912,"mangaTitle":"Welcome to Japan, Elf-san!","volume":"3","chapter":"16","title":"Conquering the Ancient Labyrinth - 2","language":"gb","groups":[6222,6293,11138],"timestamp":1593636135,"comments":79}
So they you'd use the groups key at the end of the title endpoint to find the name of each group
 
Joined
May 27, 2020
Messages
4
@Xunder
Thanks for the example :)
Yh that all makes sense, in my project I can set a preferred group, in the old v1 I would simply compare '''group_id''', I'll rewrite the logic, not a problem just wondering the context behind it so the logic can get the right chapter :)
 
Double-page supporter
Joined
Jan 17, 2018
Messages
3,198
To add on what Xunder said, there can't be a chapter without a group, since there are 2 groups for "no group" situations: Unknown and no group. Meaning, you don't even have to check for an empty array.

From the upload guidelines:
Select "Unknown" if you do not know which group to attribute the chapter to.
Select "no group" if the original scanlator does not wish to create a group for their scanlation.
 
Joined
Feb 6, 2020
Messages
3
Is there a way to find out about the different relation types the API gives back? I currently found the following by clicking through random titles but couldn't find them all, and didn't see an end-point similar to /tag.

Prequel = 1,
Sequel = 2,
AdaptedFrom = 3,
SpinOff = 4,
SideStory = 5,
MainStory = 6,
AlternateStory = 7,
Doujinshi = 8,
BasedOn = 9,
SharedUniverse = 12,
SameFranchise = 13
 
Joined
Feb 26, 2019
Messages
114
I already send some of my crypto but the status is still pending.
Anyway is this have rate limit?
 
Member
Joined
Aug 20, 2020
Messages
305
@Halo Thanks for answering.

Wow what all you guys are doing is really some interesting stuff. Makes me wish I studied computer science 😂
 
Joined
Jan 18, 2018
Messages
2
Is there a rough timeframe for deprecation of v1? Obviously I plan to update to v2 as soon as possible, but with work and other circumstances in life, updating my code to v2 is not high on the priority list.
 
Double-page supporter
Joined
Jan 17, 2018
Messages
3,198
@Yentis Get the "mangadex_session" cookie (through the login form or the ajax endpoint), then use it with your request. Important: the User-Agent has to be identical to the one you used to obtain the cookie.




@Plykiya Would it be too much to ask to create a dedicated forum section for API and third-party apps?
 
Joined
Jan 20, 2018
Messages
2
Code:
"GET /chapter/{id|hash}"
"mark_read": "(Optional) Mark the chapter as read. Boolean, default true."

Defaulting to making a change/write on `GET` is misleading, but I can understand the intent behind this. I'd say it's worth considering flipping the default.


Code:
"POST /user/{id}/marker"

There isn't any way to query read markers and isn't returned on any other endpoints. Is this just WIP?



Overall it's simple enough changes from V1.

I'd suggest for future additions would limited to a Read only endpoint(like User Settings) _or_ a Read/Write pair of endpoints. Just to avoid similar issues to read markers, as right now will need to mix APIv2 and 'Other means' to fetch those read markers.
 
Status
Not open for further replies.

Users who are viewing this thread

Top