@Path(value="/api-keys") public class ApiKeyResource extends RestResource
API_KEY_CLIENT_ID, API_KEY_TOKEN, API_KEY_USER, apiClientId, apiToken, apiUser, AUTHENTICATION_PARAM_NAME, hmacHeader, querySessionId, REMOTE_USER_ID, REMOTE_USER_TOKEN, remoteUserId, remoteUserToken, request, sessionId, WOR_PARTNER_TOKEN, worPartnerToken
Constructor and Description |
---|
ApiKeyResource() |
Modifier and Type | Method and Description |
---|---|
javax.ws.rs.core.Response |
createApiKey(String clientId)
creates an api-key for the specified client id
|
javax.ws.rs.core.Response |
deleteApiKey(String secret,
String clientId,
long id)
Delete a specified API key
|
javax.ws.rs.core.Response |
getApiKeys(int offset,
int limit,
boolean asc,
String sort,
boolean getAll)
retrieves list of api keys created by user
|
addHeaders, getThisServer, getUserId, getUserId, getWebPartner, log, requireUserId, requireUserIdOrWebPartner, requireWebPartner, respond, respond, respond, respond
@POST @Consumes(value="application/json") @Produces(value="application/json") public javax.ws.rs.core.Response createApiKey(@QueryParam(value="client_id") String clientId)
@GET @Produces(value="application/json") public javax.ws.rs.core.Response getApiKeys(@DefaultValue(value="0") @QueryParam(value="offset") int offset, @DefaultValue(value="15") @QueryParam(value="limit") int limit, @DefaultValue(value="true") @QueryParam(value="asc") boolean asc, @DefaultValue(value="creationTime") @QueryParam(value="sort") String sort, @DefaultValue(value="false") @QueryParam(value="getAll") boolean getAll)
@DELETE @Path(value="/{id}") @Produces(value="application/json") public javax.ws.rs.core.Response deleteApiKey(@QueryParam(value="secret") String secret, @QueryParam(value="clientId") String clientId, @PathParam(value="id") long id)
secret
- clientId
- id
- Copyright © 2017. All rights reserved.