1

When I call 'https://apisandbox-api.zuora.com/rest/v1/accounts' with required apiAccessKeyId, apiSecretAccessKey and parameters, I recieve the response

{
  "success": false,
  "reasons": [
    {
      "code": 90000011,
      "message": "this resource is protected, please sign in first"
    }
  ]
}

Not clear what is exact issue.

Dave Schweisguth
  • 36,475
  • 10
  • 98
  • 121

2 Answers2

2

You need to call the connection api first in order to access any object in the Zuora sandbox.

Request URL GET: https://apisandbox-api.zuora.com/rest/v1/connections

and the response you would see:

{ "success": true }

Give it a try after calling this Api. It should be resolved then.Thanks.

Rajeev
  • 29
  • 1
  • 7
0

You need to sign in first, there is an example in the Zuora SDK using a ConnectionManager source :

final ZClient Z_CLIENT = new ZClient();
final ConnectionManager cm = new ConnectionManager();
if (!cm.isConnected(Z_CLIENT, (String) ZConfig.getInstance().getVal("default.tenant.user.id"),
    (String) ZConfig.getInstance().getVal("default.tenant.password")))
{
throw new RuntimeException("Couln't open a connection to Zuora API !");
}
Benoit Vanalderweireldt
  • 2,925
  • 2
  • 21
  • 31