Package io.jans.as.server.ssa.ws.rs
Interface SsaRestWebService
-
- All Known Implementing Classes:
SsaRestWebServiceImpl
public interface SsaRestWebServiceInterface to handle all SSA REST web services.
-
-
Method Summary
All Methods Instance Methods Abstract Methods Modifier and Type Method Description jakarta.ws.rs.core.Responsecreate(String requestParams, jakarta.servlet.http.HttpServletRequest httpRequest)Create SSA for the organization with "expiration" (optional).jakarta.ws.rs.core.Responseget(String jti, String orgId, jakarta.servlet.http.HttpServletRequest httpRequest)Get list of SSA based on "jti" or "org_id" filter.jakarta.ws.rs.core.ResponsegetSsaJwtByJti(String jti)Get JWT from existing active SSA based on "jti".jakarta.ws.rs.core.Responserevoke(String jti, String orgId, jakarta.servlet.http.HttpServletRequest httpRequest)Revokes existing active SSA based on "jti" or "org_id".jakarta.ws.rs.core.Responsevalidate(String jti)Validate existing active SSA based on "jti".
-
-
-
Method Detail
-
create
@POST @Path("/ssa") @Produces("application/json") jakarta.ws.rs.core.Response create(String requestParams, @Context jakarta.servlet.http.HttpServletRequest httpRequest)Create SSA for the organization with "expiration" (optional).- Parameters:
requestParams- Valid jsonhttpRequest- Http request object- Returns:
Responsewith status201 (Created)and with body the ssa token, or with status401 (Unauthorized)if unauthorized access request, or with status500 (Internal Server Error)if internal error occurred.
-
get
@GET @Path("/ssa") @Produces("application/json") jakarta.ws.rs.core.Response get(@QueryParam("jti") String jti, @QueryParam("org_id") String orgId, @Context jakarta.servlet.http.HttpServletRequest httpRequest)Get list of SSA based on "jti" or "org_id" filter.- Parameters:
jti- Unique identifierorgId- Organization IDhttpRequest- Http request- Returns:
- the
Responsewith status200 (Ok)and with body the ssa list, or with status401 (Unauthorized)if unauthorized access request, or with status500 (Internal Server Error)if internal error occurred.
-
validate
@POST @Path("/ssa/validation") @Produces("application/json") jakarta.ws.rs.core.Response validate(@HeaderParam("jti") String jti)Validate existing active SSA based on "jti".- Parameters:
jti- Unique identifier- Returns:
Responsewith status200 (Ok)if is was validated successfully, or with status401 (Unauthorized)if unauthorized access request, or with status400 (Bad Request) with <b>invalid_jti<b/> key, when jti does not exist, is invalid or state is in (expired, used or revoked), or with status500 (Internal Server Error)if internal error occurred.
-
revoke
@DELETE @Path("/ssa") @Produces("application/json") jakarta.ws.rs.core.Response revoke(@QueryParam("jti") String jti, @QueryParam("org_id") String orgId, @Context jakarta.servlet.http.HttpServletRequest httpRequest)Revokes existing active SSA based on "jti" or "org_id".- Parameters:
jti- Unique identifierorgId- Organization IDhttpRequest- Http request- Returns:
- the
Responsewith status200 (Ok)if it was revoked successfully, or with status401 (Unauthorized)if unauthorized access request, or with status500 (Internal Server Error)if internal error occurred.
-
getSsaJwtByJti
@GET @Path("/ssa/jwt") @Produces("application/json") jakarta.ws.rs.core.Response getSsaJwtByJti(@QueryParam("jti") String jti)Get JWT from existing active SSA based on "jti".- Parameters:
jti- Unique identifier- Returns:
Responsewith status200 (Ok)and the body containing JWT of SSA. or with status401if this functionality is not enabled, request has to have at least scope "ssa.admin", or with status403if the SSA does not exist, is expired or used, or with status500in case an uncontrolled error occurs when processing the method.
-
-