Album Creation (Un-Authed / Authed)
POST https://api.imgur.com/3/album
Create a new album. Optional parameter of ids[]
is an array of image ids to add to the album. If uploading anonymous images to an anonymous album please use the optional parameter of deletehashes[]
rather than ids[]
. Note: including the optional deletehashes[]
parameter will also work for authenticated user albums. There is no need to duplicate image ids with their corresponding deletehash.
This method is available without authenticating an account, and may be used merely by sending Authorization: Client-ID {client_id}
in the request headers. Doing so will create an anonymous album which is not tied to an account.
Response Model: Basic
Parameters
Key | Required | Description |
---|---|---|
ids[] | optional | The image ids that you want to be included in the album. |
deletehashes[] | optional | The deletehashes of the images that you want to be included in the album. |
title | optional | The title of the album |
description | optional | The description of the album |
privacy | optional | Sets the privacy level of the album. Values are : public | hidden | secret. Defaults to user's privacy settings for logged in users. |
layout | optional | (deprecated) Sets the layout to display the album. Values are : blog | grid | horizontal | vertical |
cover | optional | The ID of an image that you want to be the cover of the album |
Request Body
[{"name"=>"ids[]", "value"=>"{{imageHash}}", "datatype"=>"string"}, {"name"=>"ids[]", "value"=>"{{imageHash2}}", "datatype"=>"string"}, {"name"=>"deletehashes[]", "value"=>"{{deleteHash}}", "datatype"=>"string"}, {"name"=>"deletehashes[]", "value"=>"{{deleteHash2}}", "datatype"=>"string"}, {"name"=>"title", "value"=>"My dank meme album", "datatype"=>"string"}, {"name"=>"description", "value"=>"This albums contains a lot of dank memes. Be prepared.", "datatype"=>"string"}, {"name"=>"privacy", "value"=>"public", "datatype"=>"string"}, {"name"=>"cover", "value"=>"{{imageHash}}", "datatype"=>"string"}]
HEADERS
Key | Datatype | Required | Description |
---|---|---|---|
Authorization | string | Use this header if performing this action anonymously. | |
Authorization | string | Use this header if performing this action as a logged-in user. |