Package com.xebialabs.xlrelease.api.v1

# Interface DeliveryApi

All Superinterfaces:
  `ApiService`

@Path("/api/v1/deliveries") @Produces("application/json") @Consumes("application/json") public interface DeliveryApi extends ApiService
Operations on release deliveries.

- ## Field Summary

  ### Fields inherited from interface com.xebialabs.xlrelease.api.ApiService

  `DEFAULT_RESULTS_PER_PAGE, DEFAULT_RESULTS_PER_PAGE_STRING, DEPTH, ORDER_BY, PAGE, PAGE_IS_OFFSET, RESULTS_PER_PAGE, ROLE_IDS_DATA`

- ## Method Summary

  Modifier and Type
  Method
  Description
  `void`
  `completeStage(String stageId)`
  Completes a stage in a delivery.
  `void`
  `completeTrackedItem(String stageId, String itemId)`
  Completes a tracked item in stage.
  `void`
  `completeTrackedItem(String stageId, String itemId, String releaseId)`
  Completes a tracked item in stage.
  `void`
  `completeTransition(String transitionId, CompleteTransition completeTransition)`
  Executes a transition on a delivery manually.
  `TrackedItem`
  `createTrackedItem(String deliveryId, TrackedItem item)`
  Adds a tracked item to a delivery.
  `void`
  `deleteDelivery(String deliveryId)`
  Deletes a delivery.
  `void`
  `deleteTrackedItem(String itemId)`
  Deletes a tracked item.
  `void`
  `descopeTrackedItem(String itemId)`
  Descopes a tracked item.
  `Delivery`
  `getDelivery(String deliveryId)`
  Returns a delivery by ID.
  `DeliveryTimeline`
  `getDeliveryTimeline(String deliveryId)`
  `List<DeliveryFlowReleaseInfo>`
  `getReleases(String deliveryId)`
  Returns releases associated with a given delivery.
  `List<Stage>`
  `getStages(String deliveryId)`
  Returns the stages in a given delivery.
  `List<TrackedItem>`
  `getTrackedItems(String deliveryId)`
  Returns the tracked items associated with given delivery.
  `List<TrackedItem>`
  `markTrackedItemsInStage(String deliveryId, String stageIdOrTitle, List<String> itemIdOrTitles, TrackedItemStatus status, boolean precedingStages, String releaseId)`
  `SubscriptionResult`
  `registerSubscriber(String deliveryId, Subscriber subscriber)`
  `void`
  `registerTrackedItems(String deliveryId, List<String> itemIdOrTitles, String fromReleaseId)`
  `void`
  `reopenStage(String stageId)`
  Reopens a closed stage in a delivery.
  `void`
  `rescopeTrackedItem(String itemId)`
  Rescopes a tracked item.
  `void`
  `resetTrackedItem(String stageId, String itemId)`
  `List<Delivery>`
  `searchDeliveries(DeliveryFilters deliveryFilters)`
  Search deliveries by filters with default pagination and ordering by title.
  `List<Delivery>`
  `searchDeliveries(DeliveryFilters deliveryFilters, DeliveryOrderMode orderBy)`
  Search deliveries by filters with default pagination.
  `List<Delivery>`
  `searchDeliveries(DeliveryFilters deliveryFilters, Long page, Long resultsPerPage, DeliveryOrderMode orderBy)`
  Search deliveries by filters.
  `default String`
  `serviceName()`
  `void`
  `skipTrackedItem(String stageId, String itemId)`
  Skips a tracked item in stage.
  `Delivery`
  `updateDelivery(Delivery delivery)`
  Updates a delivery.
  `Delivery`
  `updateDelivery(String deliveryId, Delivery delivery)`
  Updates a delivery.
  `Stage`
  `updateStage(Stage stage)`
  Updates a stage in a delivery.
  `Stage`
  `updateStage(String stageId, Stage stage)`
  Updates a stage in a delivery.
  `TrackedItem`
  `updateTrackedItem(TrackedItem item)`
  Updates a tracked item.
  `TrackedItem`
  `updateTrackedItem(String itemId, TrackedItem item)`
  Updates a tracked item.
  `Transition`
  `updateTransition(Transition transition)`
  Updates a transition on a delivery.
  `Transition`
  `updateTransition(String transitionId, Transition transition)`
  Updates a transition on a delivery.

- ## Method Details

  - ### serviceName

    default String serviceName()
    Specified by:
      `serviceName` in interface `ApiService`

  - ### getDelivery

    @GET @Path("/{deliveryId:.*Delivery[^/]*}") Delivery getDelivery(@PathParam("deliveryId") String deliveryId)
    Returns a delivery by ID.
    Parameters:
      `deliveryId` - the delivery identifier.
    Returns:
      the delivery which has the given identifier.

  - ### updateDelivery

    @PUT @Path("/{deliveryId:.*Delivery[^/]*}") Delivery updateDelivery(@PathParam("deliveryId") String deliveryId, Delivery delivery)
    Updates a delivery.
    Parameters:
      `deliveryId` - the delivery identifier.
      `delivery` - new contents of the delivery.
    Returns:
      the updated delivery.

  - ### updateDelivery

    Delivery updateDelivery(Delivery delivery)
    Updates a delivery.
    Parameters:
      `delivery` - new contents of the delivery.
    Returns:
      the updated delivery.

  - ### deleteDelivery

    @DELETE @Path("/{deliveryId:.*Delivery[^/]*}") void deleteDelivery(@PathParam("deliveryId") String deliveryId)
    Deletes a delivery.
    Parameters:
      `deliveryId` - the delivery identifier.

  - ### searchDeliveries

    @POST @Path("search") List<Delivery> searchDeliveries(DeliveryFilters deliveryFilters, @DefaultValue("0") @QueryParam("page") Long page, @DefaultValue("100") @QueryParam("resultsPerPage") Long resultsPerPage, @DefaultValue("START_DATE") @QueryParam("orderBy") DeliveryOrderMode orderBy)
    Search deliveries by filters.
    Parameters:
      `deliveryFilters` - the search criteria.
      `page` - the page of results to return. Default value is 0.
      `resultsPerPage` - the number of results per page. Default and maximum value is 100.
      `orderBy` - sort options by which to sort the deliveries. Leave null for ordering by title.
    Returns:
      the list of matching deliveries.

  - ### searchDeliveries

    List<Delivery> searchDeliveries(DeliveryFilters deliveryFilters, DeliveryOrderMode orderBy)
    Search deliveries by filters with default pagination.
    Parameters:
      `deliveryFilters` - the search criteria.
      `orderBy` - sort options by which to sort the deliveries. Leave null for ordering by title.
    Returns:
      the list of matching deliveries.

  - ### searchDeliveries

    List<Delivery> searchDeliveries(DeliveryFilters deliveryFilters)
    Search deliveries by filters with default pagination and ordering by title.
    Parameters:
      `deliveryFilters` - the search criteria.
    Returns:
      the list of matching deliveries.

  - ### getDeliveryTimeline

    @GET @Path("/{deliveryId:.*Delivery[^/]*}/timeline") DeliveryTimeline getDeliveryTimeline(@PathParam("deliveryId") String deliveryId)

  - ### getReleases

    @GET @Path("/{deliveryId:.*Delivery[^/]*}/releases") List<DeliveryFlowReleaseInfo> getReleases(@PathParam("deliveryId") String deliveryId)
    Returns releases associated with a given delivery.
    Parameters:
      `deliveryId` - the delivery identifier.
    Returns:
      the release info associated with the delivery.

  - ### registerSubscriber

    SubscriptionResult registerSubscriber(String deliveryId, Subscriber subscriber)

  - ### createTrackedItem

    @POST @Path("/{deliveryId:.*Delivery[^/]*}/tracked-items") TrackedItem createTrackedItem(@PathParam("deliveryId") String deliveryId, TrackedItem item)
    Adds a tracked item to a delivery.
    Parameters:
      `deliveryId` - the delivery identifier.
      `item` - the item to be added to the delivery.
    Returns:
      the created item.

  - ### getTrackedItems

    @GET @Path("/{deliveryId:.*Delivery[^/]*}/tracked-items") List<TrackedItem> getTrackedItems(@PathParam("deliveryId") String deliveryId)
    Returns the tracked items associated with given delivery.
    Parameters:
      `deliveryId` - the delivery identifier.
    Returns:
      tracked items associated with the delivery.

  - ### updateTrackedItem

    @PUT @Path("/{itemId:.*TrackedItem[^/]*}") TrackedItem updateTrackedItem(@PathParam("itemId") String itemId, TrackedItem item)
    Updates a tracked item.
    Parameters:
      `itemId` - the full item identifier.
      `item` - new contents of the item.
    Returns:
      the updated item.

  - ### updateTrackedItem

    TrackedItem updateTrackedItem(TrackedItem item)
    Updates a tracked item.
    Parameters:
      `item` - new contents of the item.
    Returns:
      the updated item.

  - ### deleteTrackedItem

    @DELETE @Path("/{itemId:.*TrackedItem[^/]*}") void deleteTrackedItem(@PathParam("itemId") String itemId)
    Deletes a tracked item.
    Parameters:
      `itemId` - the full item identifier.

  - ### descopeTrackedItem

    @PUT @Path("/{itemId:.*TrackedItem[^/]*}/descope") void descopeTrackedItem(@PathParam("itemId") String itemId)
    Descopes a tracked item.
    Parameters:
      `itemId` - the full item identifier.

  - ### rescopeTrackedItem

    @PUT @Path("/{itemId:.*TrackedItem[^/]*}/rescope") void rescopeTrackedItem(@PathParam("itemId") String itemId)
    Rescopes a tracked item.
    Parameters:
      `itemId` - the full item identifier.

  - ### completeTrackedItem

    @PUT @Path("/{stageId:.*Stage[^/]*}/{itemId:.*TrackedItem[^/]*}/complete") void completeTrackedItem(@PathParam("stageId") String stageId, @PathParam("itemId") String itemId)
    Completes a tracked item in stage.
    Parameters:
      `stageId` - the full stage identifier.
      `itemId` - the item identifier.

  - ### completeTrackedItem

    @PUT @Path("/{stageId:.*Stage[^/]*}/{itemId:.*TrackedItem[^/]*}/{releaseId:.*Release[^/]*}/complete") void completeTrackedItem(@PathParam("stageId") String stageId, @PathParam("itemId") String itemId, @PathParam("releaseId") String releaseId)
    Completes a tracked item in stage.
    Parameters:
      `stageId` - the full stage identifier.
      `itemId` - the item identifier.
      `releaseId` - the release identifier that completed item.

  - ### skipTrackedItem

    @PUT @Path("/{stageId:.*Stage[^/]*}/{itemId:.*TrackedItem[^/]*}/skip") void skipTrackedItem(@PathParam("stageId") String stageId, @PathParam("itemId") String itemId)
    Skips a tracked item in stage.
    Parameters:
      `stageId` - the full stage identifier.
      `itemId` - the item identifier.

  - ### resetTrackedItem

    @PUT @Path("/{stageId:.*Stage[^/]*}/{itemId:.*TrackedItem[^/]*}/reset") void resetTrackedItem(@PathParam("stageId") String stageId, @PathParam("itemId") String itemId)

  - ### registerTrackedItems

    void registerTrackedItems(String deliveryId, List<String> itemIdOrTitles, String fromReleaseId)

  - ### markTrackedItemsInStage

    List<TrackedItem> markTrackedItemsInStage(String deliveryId, String stageIdOrTitle, List<String> itemIdOrTitles, TrackedItemStatus status, boolean precedingStages, String releaseId)

  - ### getStages

    @GET @Path("/{deliveryId:.*Delivery[^/]*}/stages") List<Stage> getStages(@PathParam("deliveryId") String deliveryId)
    Returns the stages in a given delivery.
    Parameters:
      `deliveryId` - the delivery identifier.
    Returns:
      stages in the delivery.

  - ### completeStage

    @POST @Path("/{stageId:.*Stage[^/]*}/complete") void completeStage(@PathParam("stageId") String stageId)
    Completes a stage in a delivery.
    Parameters:
      `stageId` - the full stage identifier.

  - ### reopenStage

    @POST @Path("/{stageId:.*Stage[^/]*}/reopen") void reopenStage(@PathParam("stageId") String stageId)
    Reopens a closed stage in a delivery.
    Parameters:
      `stageId` - the full stage identifier.

  - ### updateStage

    Stage updateStage(Stage stage)
    Updates a stage in a delivery.
    Parameters:
      `stage` - new contents of the stage.
    Returns:
      the updated stage.

  - ### updateStage

    @PUT @Path("/{stageId:.*Stage[^/]*}") Stage updateStage(@PathParam("stageId") String stageId, Stage stage)
    Updates a stage in a delivery.
    Parameters:
      `stageId` - the full stage identifier.
      `stage` - new contents of the stage.
    Returns:
      the updated stage.

  - ### updateTransition

    @PUT @Path("/{transitionId:.*Transition[^/]*}") Transition updateTransition(@PathParam("transitionId") String transitionId, Transition transition)
    Updates a transition on a delivery.
    Parameters:
      `transitionId` - the full transition identifier.
      `transition` - new contents of the transition.
    Returns:
      the updated transition

  - ### updateTransition

    Transition updateTransition(Transition transition)
    Updates a transition on a delivery.
    Parameters:
      `transition` - new contents of the transition.
    Returns:
      the updated transition

  - ### completeTransition

    @POST @Path("/{transitionId:.*Transition[^/]*}/complete") void completeTransition(@PathParam("transitionId") String transitionId, CompleteTransition completeTransition)
    Executes a transition on a delivery manually.
    Parameters:
      `transitionId` - the full transition identifier.
      `completeTransition` - the transition completion parameters.