Interface IIssuer

All Known Implementing Classes:
ManualIssuerImplementation

public interface IIssuer
  • Method Details

    • getIssuerId

      String getIssuerId()
      Unique issuer identifier that is used for routing requests to proper issuer. This identifier should match the issuerId specified in a request.
      Returns:
      issuer identifier
    • submitOrder

      Submit order to be created by an issuer. If throwing IdIssuerRequestSleepException the resulting request status will be REQUEST_PENDING, meaning that the request was not successfully submitted.
      Parameters:
      request - order to be submitted for creation by an issuer
      Returns:
      creation result containing status and ID used by issuer
      Throws:
      IdIssuerRequestSleepException
    • fetchOrderStatus

      OrderStatusResponse fetchOrderStatus(OrderStatusRequest request, ExtraParams extraParams) throws IdIssuerRequestSleepException
      Obtain status of submitted order
      Parameters:
      request - specifies what product and order
      Returns:
      status of a particular product
      Throws:
      IdIssuerRequestSleepException
    • fetchOrder

      Obtain all product ids of an order
      Parameters:
      request - specify what ids to obtain
      Returns:
      all order product ids
      Throws:
      IdIssuerRequestSleepException
    • allowsInstantIdDownload

      default boolean allowsInstantIdDownload()
      Method indicates whether IDs can be generated on the spot or if the generation process takes a long time because the issuer is an external one. For asynchronous issuers, a polling service is used to check and update the status.
      Returns:
      true if issuer can respond synchronously, false otherwise
    • closeOrder

      default void closeOrder(CloseOrderRequest request, ExtraParams extraParams) throws IdIssuerRequestSleepException
      Close out open order
      Parameters:
      request - specify which order to close
      Throws:
      IdIssuerRequestSleepException
    • enforceRequeueDelayAfterStatusUpdate

      default boolean enforceRequeueDelayAfterStatusUpdate()
      Override this to enforce a delay (governed by module-id.id-monitoring-delay-seconds) before we start processing the next "stage". This is needed for e.g. CRPT
      Returns:
      true if delay should be enforced
    • autoCloseOrderWhenDownloaded

      default boolean autoCloseOrderWhenDownloaded()
      Override this to automatically close an id order on the regulation as soon as it has been downloaded. Only do this if the order is not required to be open for utilization.
      Returns:
      true if closeOrder should be invoked right after downloading all ids
    • canPoll

      default boolean canPoll(QueuedIdRequest queuedIdRequest)
      The issuer implementation can decide against polling. If returning false, please ensure that the queuedIdRequest is cleaned up eventually.
      Parameters:
      queuedIdRequest - to verify
      Returns:
      true if polling is allowed, otherwise false
    • allowsManualFulfillment

      default boolean allowsManualFulfillment()
    • manuallyFulfillOrder

      default void manuallyFulfillOrder(IdRequest idRequest, List<String> ids)