Frage

I have created an application in Box and got an API Key, and then edited the redirect URL. But when I accessed through URL https://www.box.net/api/1.0/rest?action=get_ticket&api_key=APIKEY, I'm not getting a positive response, instead of I'm getting a response like:

<response>
<status>application_restricted</status>
</response>

Please provide me a solution to get access to the application. Thanks in advance.

War es hilfreich?

Lösung

The V1 API has been deprecated and will no longer provide authentication or file access. You need to migrate your application to the V2 API, which is documented here.

Andere Tipps

For accessing access_token using java sdk , You need to have following key values

1) clienId > Use Application console

2) client_secret > Use application console

3) code > Code value you will get using below link https://account.box.com/api/oauth2/authorize?response_type=code&client_id={your_client_id}&state=security_token%3DKnhMJatFipTAnM0nHlZA

Replace your client id with original value. client id you will get from your apps.

And Follow steps and authorize you application using your credential.

after that it will redirect to https://localhost/?state=security_token%3DKnhMJatFipTAnM0nHlZA&code=sdsdsd3sdsdC0oGqOS2WgaFipZBdj

Copy code value

String clienId = "your client id ";

String client_secret = "your secret id"; 

String code = "sdsdsd3sdsdC0oGqOS2WgaFipZBdj"; // use above extracted  code value 
BoxAPIConnection con = new BoxAPIConnection(clienId,client_secret,code);

String accessToken = con.getAccessToken();

System.out.println("Accss_Token : " +accessToken);
Lizenziert unter: CC-BY-SA mit Zuschreibung
Nicht verbunden mit StackOverflow
scroll top