code: public Token getXAuthorizationToken(final ContainerRequest request) {
          final String xAuthorizationString = request.getHeaderString("X-Authorization");
          if (xAuthorizationString != null && !"".equals(xAuthorizationString)) {
              return Token.fromString(xAuthorizationString.trim());
          }
          return null;
      }
docs: Extract a Fernet token from an X-Authorization header.
  
  @param request a REST request which may or may not include an X-Authorization header.
  @return a Fernet token or null if no X-Authorization header is provided.