Rocketfuel

Rocketfuel is the consumer client for the Marketplace Publishing Tool. It has some special APIs that are not recommended for consumption by other clients.

These APIs will change in conjunction with the Rocketfuel client, which is under active development.

Warning

This API is for internal use only at this time. It SHOULD NOT be used externally by third parties. It is not considered stable and WILL change over time.

Collections

Deprecated since version 2: The collection endpoints were moved to the feed.

A collection is a group of applications

Note

The name and description fields are user-translated fields and have a dynamic type depending on the query. See translations.

Listing

GET /api/v2/rocketfuel/collections/

A listing of all collections.

Note

Authentication is optional.

Request:

The following query string parameters can be used to filter the results:

Parameters:
  • cat (string) – a category slug.
  • region (int|string) – a region ID/slug.
  • carrier (int|string) – a carrier ID/slug.

Filtering on null values is done by omiting the value for the corresponding parameter in the query string.

If no results are found with the filters specified, the API will automatically use a fallback mechanism and try to change the values to null in order to try to find some results.

The order in which the filters are set to null is:
  1. region
  2. carrier
  3. region and carrier.

In addition, if that fallback mechanism is used, HTTP responses will have an additional API-Fallback header, containing the fields which were set to null to find the returned results, separated by a comma if needed, like this:

API-Fallback: region, carrier

Create

POST /api/v2/rocketfuel/collections/

Create a collection.

Note

Authentication and the ‘Collections:Curate’ permission are required.

Request:

Parameters:
  • author (string) – the author of the collection.
  • background_color (string|null) – the background of the overlay on the image when collection is displayed (hex-formatted, e.g. “#FF00FF”). Only applies to curated collections (i.e. when collection_type is 0).
  • can_be_hero (boolean) – whether the collection may be featured with a hero graphic. This may only be set to true for operator shelves. Defaults to false.
  • carrier (int|null) – the ID of the carrier to attach this collection to. Defaults to null.
  • category (slug|null) – the slug of the category to attach this collection to. Defaults to null.
  • collection_type (int) – the type of collection to create.
  • description (string|object) – a description of the collection.
  • is_public (boolean) – an indication of whether the collection should be displayed in consumer-facing pages. Defaults to false.
  • name (string|object) – the name of the collection.
  • region (int|null) – the ID of the region to attach this collection to. Defaults to null.
  • slug (string|null) – a slug to use in URLs for the collection. Automatically generated if not specified.
  • text_color (string|null) – the color of the text displayed on the overlay on the image when collection is displayed (hex-formatted, e.g. “#FF00FF”). Only applies to curated collections (i.e. when collection_type is 0).

Detail

GET /api/v2/rocketfuel/collections/(int:id|string:slug)/

Get a single collection.

Note

Authentication is optional.

Update

PATCH /api/v2/rocketfuel/collections/(int:id|string:slug)/

Update a collection.

Note

Authentication and one of the ‘Collections:Curate’ permission or curator-level access to the collection are required.

Note

The can_be_hero field may not be modified unless you have the Collections:Curate permission, even if you have curator-level access to the collection.

Request:

Parameters:
  • author (string) – the author of the collection.
  • can_be_hero (boolean) – whether the collection may be featured with a hero graphic. This may only be set to true for operator shelves. Defaults to false.
  • carrier (int|null) – the ID of the carrier to attach this collection to.
  • category (string|null) – the slug of the category to attach this collection to.
  • collection_type (int) – the type of the collection.
  • description (string|object) – a description of the collection.
  • name (string|object) – the name of the collection.
  • region (int|null) – the ID of the region to attach this collection to.
  • slug (string|null) – a slug to use in URLs for the collection.

Response:

A representation of the updated collection will be returned in the response body.

Status Codes:
  • 200 OK – collection successfully updated.
  • 400 Bad Request – invalid request; more details provided in the response body.

Duplicate

POST /api/v2/rocketfuel/collections/(int: id)/duplicate/

Duplicate a collection, creating and returning a new one with the same properties and the same apps.

Note

Authentication and one of the ‘Collections:Curate’ permission or curator-level access to the collection are required.

Note

The can_be_hero field may not be modified unless you have the Collections:Curate permission, even if you have curator-level access to the collection.

Request:

Any parameter passed will override the corresponding property from the duplicated object.

Parameters:
  • author (string) – the author of the collection.
  • can_be_hero (boolean) – whether the collection may be featured with a hero graphic. This may only be set to true for operator shelves. Defaults to false.
  • carrier (int|null) – the ID of the carrier to attach this collection to.
  • category (string|null) – the slug of the category to attach this collection to.
  • collection_type (int) – the type of the collection.
  • description (string|object) – a description of the collection.
  • name (string|object) – the name of the collection.
  • region (int|null) – the ID of the region to attach this collection to.
  • slug (string|null) – a slug to use in URLs for the collection.

Response:

A representation of the duplicate collection will be returned in the response body.

Status Codes:
  • 201 Created – collection successfully duplicated.
  • 400 Bad Request – invalid request; more details provided in the response body.

Delete

DELETE /api/v2/rocketfuel/collections/(int:id|string:slug)/

Delete a single collection.

Note

Authentication and the ‘Collections:Curate’ permission are required.

Response:

Status Codes:
  • 204 No Content – collection successfully deleted.
  • 400 Bad Request – invalid request; more details provided in the response body.
  • 403 Forbidden – not authenticated or authenticated without permission; more details provided in the response body.

Add Apps

POST /api/v2/rocketfuel/collections/(int:id|string:slug)/add_app/

Add an application to a single collection.

Note

Authentication and one of the ‘Collections:Curate’ permission or curator-level access to the collection are required.

Request:

Parameters:
  • app (int) – the ID of the application to add to this collection.

Response:

A representation of the updated collection will be returned in the response body.

Status Codes:
  • 200 OK – app successfully added to collection.
  • 400 Bad Request – invalid request; more details provided in the response body.

Remove Apps

POST /api/v2/rocketfuel/collections/(int:id|string:slug)/remove_app/

Remove an application from a single collection.

Note

Authentication and one of the ‘Collections:Curate’ permission or curator-level access to the collection are required.

Request:

Parameters:
  • app (int) – the ID of the application to remove from this collection.

Response:

A representation of the updated collection will be returned in the response body.

Status Codes:
  • 200 OK – app successfully removed from collection.
  • 205 Reset Content – app not a member of the collection.
  • 400 Bad Request – invalid request; more details provided in the response body.

Reorder Apps

POST /api/v2/rocketfuel/collections/(int:id|string:slug)/reorder/

Reorder applications in a collection.

Note

Authentication and one of the ‘Collections:Curate’ permission or curator-level access to the collection are required.

Request:

The body of the request must contain a list of apps in their desired order.

Example:

[18, 24, 9]

Response:

A representation of the updated collection will be returned in the response body.

Status Codes:
  • 200 OK – collection successfully reordered.
  • 400 Bad Request – all apps in the collection not represented in response body. For convenience, a list of all apps in the collection will be included in the response.

Image

GET /api/v2/rocketfuel/collections/(int:id|string:slug)/image/

Get the image for a collection.

Note

Authentication is optional.

PUT /api/v2/rocketfuel/collections/(int:id|string:slug)/image/

Set the image for a collection. Accepts a data URI as the request body containing the image, rather than a JSON object.

Note

Authentication and one of the ‘Collections:Curate’ permission or curator-level access to the collection are required.

DELETE /api/v2/rocketfuel/collections/(int:id|string:slug)/image/

Delete the image for a collection.

Note

Authentication and one of the ‘Collections:Curate’ permission or curator-level access to the collection are required.

Curators

Users can be given object-level access to collections if they are marked as curators. The following API endpoints allow manipulation of a collection’s curators:

Listing

GET /api/v2/rocketfuel/collections/(int:id|string:slug)/curators/

Get a list of curators for a collection.

Note

Authentication and one of the ‘Collections:Curate’ permission or curator-level access to the collection are required.

Response:

Example:

[
    {
        'display_name': 'Basta',
        'email': 'support@bastacorp.biz',
        'id': 30
    },
    {
        'display_name': 'Cvan',
        'email': 'chris@vans.com',
        'id': 31
    }
]

Add Curator

POST /api/v2/rocketfuel/collections/(int:id|string:slug)/add_curator/

Add a curator to this collection.

Note

Authentication and one of the ‘Collections:Curate’ permission or curator-level access to the collection are required.

Request:

Parameters:
  • user (int|string) – the ID or email of the user to add as a curator of this collection.

Response:

A representation of the updated list of curators for this collection will be returned in the response body.

Status Codes:
  • 200 OK – user successfully added as a curator of this collection.
  • 400 Bad Request – invalid request; more details provided in the response body.
  • 403 Forbidden – not authenticated or authenticated without permission; more details provided in the response body.

Remove Curator

POST /api/v2/rocketfuel/collections/(int:id|string:slug)/remove_curator/

Remove a curator from this collection.

Note

Authentication and one of the ‘Collections:Curate’ permission or curator-level access to the collection are required.

Request:

Parameters:
  • user (int|string) – the ID or email of the user to remove as a curator of this collection.

Response:

Status Codes:
  • 205 Reset Content – user successfully removed as a curator of this collection.
  • 400 Bad Request – invalid request; more details provided in the response body.
  • 403 Forbidden – not authenticated or authenticated without permission; more details provided in the response body.