Permission to reverse engineer the Bunpro API

I was reading through a topic called “Bunpro API when?” For information on the Bunpro API.

Found that it is not currently available by design, not because the team don’t want it but more because it is more effort when the team has other focuses.

This message indicates that the team is okay if members of the community want to reverse engineer the API.

This is me requesting permission to do so and to share the API methods I find in a GitHub public repository?

Looking forward to a response

4 Likes

Welcome to the forums~ :tada:

Thanks for asking!

Yeah you can, that’s fine.
Just note that they may change without warning :sweat_smile:

2 Likes

Hi @Sean :wave:,

Thank you for the update :arrow_up:. Glad to hear it​:ear:. I’ll make it a plan to keep the API as up to date as I can and make the necessary changes as and when the Bunpro team make updates :gear:.

Thank’s again for the confirmation :white_check_mark:, for the time being I will use a link to this post and a s screenshot of the post in the repository as a bit of an open permission for this and if that licence ever changes please feel free to let me know here :point_left:

1 Like

(Can we get a link to the GitHub repo?)

2 Likes

Sorry, I only just got around to spinning up the Repository and I haven’t yet done much by way of documenting the API.

Here is the repository that I intend to use for this project:

3 Likes

Awesome work! I just want a way to sync my known words from other tools like Migaku or jiten.moe to Bunpro. And maybe back to those tools so they’re all in sync.

As it is now, I have to mark each vocab myself as mastered in Bunpro from a deck that has the vocab.

As I can see it, since I need the deck id and reviewable id + type to mark a word as known, I need to first fetch all the reviewables in a deck somehow. My plan then would be to match and mark each reviewable in the deck to a list of known words from another system. The marked words I would then run through the “mark as mastered” api endpoint.

If there is no way to use an api to fetch all the reviewables, the only choice would be to scrape the html for deck id + vocab data so I can create my own data structure and then go from there.

@Sean Is it still OK to scrape the site for data like this if there is no API available?

1 Like

Hi there!
You don’t need the Deck ID to Mark something as Mastered.
Try “Mark as Mastered” directly from a Vocab page and check the payload.

If there is no way to use an api to fetch all the reviewables, the only choice would be to scrape the html for deck id + vocab data so I can create my own data structure and then go from there.

Would probs be easier to use the Search API (check the /search page)

Otherwise I can probs generate a CSV with all our Vocab IDs + slugs + titles + jmdict IDs

2 Likes

Hey @Sean,

Two question, first, would it be possible for the team to switch out the API token in the user settings (which currently does nothing for the available API) with the API token currently used by each user for the from end (the one that we currently have to get from the console to use the API).

The second ask is a little more involved, but would it be possible to add a frontend API endpoint that could retrieve this token from the profile using a kind of OAuth or something?

I’m currently building the documentation into an Open API documentation, and happy to have the note about how users can grab their token, but would be great if there was an API related way they could grab the token or update their token as needed

:vulcan_salute:t3: :v:t3: :metal:t3: