[bd] API

[bd] API 1.6.3

No permission to download
@xfrocks
Many thanks for time dedicated on this example.
To be honest, me too, as @Davey-UK, finding it not very intuitive.
Everytime i'm filling the fields, i'm receiving some "?error=redirect_uri_mismatch" or just bunch of text on backend. :unsure:

UPD:
Meanwhile found more detailed description of the process here: https://github.com/xfrocks/bdApi/blob/master/docs/api.markdown (about oauth2-2015030602 and whole the process). Will try to upgrade plugin again and test using info from here. Thanks!
I see your pain. It is being addressed and should make the process easier in the next release.
 
The one thing i dont really get, is why is the option for api settings in every users control panel settings? I just basically want to use it to call up functions to display login etc, that i setup as an admin.
Looking forward to the next release.
I remember the api for VBulletin a number of years ago, where we added a file or files, then basically included an include in the page we wanted it to display, something like #include_login_form or something like.
Am i getting this api totally wrong in what it does?
 
The one thing i dont really get, is why is the option for api settings in every users control panel settings? I just basically want to use it to call up functions to display login etc, that i setup as an admin.
Looking forward to the next release.
I remember the api for VBulletin a number of years ago, where we added a file or files, then basically included an include in the page we wanted it to display, something like #include_login_form or something like.
Am i getting this api totally wrong in what it does?
Well, the old design only works if your other website happens to run on the same server. This add-on is designed to work even if your site is running on a different server. Much more flexible (so a bit more complicated).

The settings page in UCP is for user to manage which API client has access to which part of their account. You will find something similar if you use Facebook and visit their application management page.
 
In your demo, the API appears to support the resource manager. I'm working with some friends on a site which uses the resource manager, however there does not appear to be a controller in the ControllerApi directory that would support the functionality shown in your demo. Does this come from a newer version or a separate add-on?
 
@xfrocks

Not sure if you're familiar with GitHub's API system, but it has a concept of 'personal access tokens' which users can generate themselves for interacting with the API:
upload_2015-4-18_1-27-54.webp

This would be a really cool addition if possible.
 
I'm getting a route not found error for all of the end points :X

bd API Consumer is working fine for me though
Looks like your site is using friendly SEO but you haven't configured .htaccess (or similar) for the api directory. [bd] API Consumer still works because it always use the "ugly" urls like api/index.php?oauth/token instead of api/oauth/token
 
Looks like your site is using friendly SEO but you haven't configured .htaccess (or similar) for the api directory. [bd] API Consumer still works because it always use the "ugly" urls like api/index.php?oauth/token instead of api/oauth/token

Hmm, I'm running nginx. Would I just set a new location block for the api folder?

Edit: Did it with a rewrite

Code:
rewrite ^/api/(.*)$ /api/index.php?$1 break;
 
Last edited:
Hmm, I'm running nginx. Would I just set a new location block for the api folder?
Yes, if you want to use friendly url for the api urls then configure the block so it's similar to XenForo root. Next version of the API won't even generate friendly urls though.
 
Top Bottom