akameco / pixiv-app-api

Promise base pixiv API client
https://www.npmjs.com/package/pixiv-app-api
MIT License
217 stars 29 forks source link

Deprecated Examples & userFollowAdd not working #11

Open yanagiragi opened 6 years ago

yanagiragi commented 6 years ago
English - version: - `node` version: v8.12.0 - `npm` (or `yarn`) version: 6.4.1 **Do you want to request a _feature_ or report a _bug_?:** 2 bugs **What is the current behavior?:** 1. readme ```login``` example has been deprecated. 2. ```userFollowAdd``` is not working Tried: * ```userFollowAdd('4197637') ``` * After login, call ```userFollowAdd('4197637') ``` * ```userFollowAdd('4197637', {'publicity': 'public'}) ``` * ```userFollowAdd({'target_user_id': '4197637', 'publicity': 'public'}) ``` **What is the expected behavior?:** 1. See [here](https://github.com/akameco/pixiv-app-api/compare/master...yanagiragi:master) for visualize comparision 2. Should call as ```userFollowId(USER_ID_YOU_WISH_TO_FOLLOW)``` and successfully add to following list **Suggested solution:** I tried to implemented with reference of upbit/pixivpy Here is the [code](https://github.com/yanagiragi/Pixiv-Downloader/blob/master/src/yrPixiv.js#L294-L311). (Sorry for using request, I'm not familiar with Axios) However, the implementation require pass access token in headers, so it may need to re-design ```instance``` in index.js, so I'm not sure which design suit best. From other APIs, I'd tried * login * searchIllust * illustRanking * illustDetail the above APIs worked fine 👍
akameco commented 6 years ago

@yanagiragi Thank you. I'll fix it.

austinhuang0131 commented 4 years ago

illustBookmarkAdd doesn't work, pixiv seems to have removed that endpoint. However, adding bookmark still works on PixivDeck. Is it possible to temporarily port the solution from PD?

cyperdark commented 4 years ago

userFollowAdd & remove throw me 404 error, any fixes for that?