API Reference: Media.Browse
Returns images included media gallery.
Input Parameters
Following parameters are required by this command:
- APIKey
Your user account API key. You can learn your API key in your Sendloop area > Manage Account section - Command
For subscribing an email address, you should set this parameter to 'Media.Browse'
Output
Sendloop will return some information about the request status. Sendloop always return in XML-RPC format. Below, you can see the list of all available codes and messages which can be returned by this command:
Error Codes and Messages:
One of the following error messages will be returned if any error occurs:
- #1
Connection type is not compatible - #2
Invalid API key or user account is not available
Success Message
Success message will include the following three parameters:
- Status
'Completed' will be returned - MediaURLX
This will be repeated for each image in the media library. X is the counter which starts from 1.
Examples
We provided examples in all three accepted messaging formats. Bold texts means data that needs to be replaced by you.
HTTP-POST Example
Input:
POST /api/index.php HTTP/1.1 Host: yoursubdomain.sendloop.com Content-Type: application/x-www-form-urlencoded FormValue_APIKey=YourAPIKeyHere&FormValue_Command=Media.Browse
HTTP-GET Example
Even this command accepts HTTP-GET method, we strongly recommend you to use HTTP-POST or XML-RPC methods
GET /api/index.php?APIKey=YourAPIKeyHere&Command=Media.Browse HTTP/1.1 Host: yoursubdomain.sendloop.com
XML-RPC Example
To connect Sendloop API through XML-RPC messaging format, you will need to pass XML-RPC code via HTTP-POST or HTTP-GET method:
XML-RPC connection via HTTP-POST:
POST /api/index.php HTTP/1.1 Host: yoursubdomain.sendloop.com Content-Type: application/x-www-form-urlencoded FormValue_Message=<<<The following XML structure must be inserted here with URL
encoded structure>>> <Entry> <Message> <APIKey>YourAPIKeyHere</APIKey> <Command>Media.Browse</Command> </Message> </Entry>
XML-RPC connection via HTTP-GET:
GET /api/index.php?FormValue_Message=<<<The following XML structure must be
inserted here with URL encoded structure>>> HTTP/1.1 Host: yoursubdomain.sendloop.com <Entry> <Message> <APIKey>YourAPIKeyHere</APIKey> <Command>Media.Browse</Command> </Message> </Entry>
Error Output Example
<value> <struct> <member> <name>APIError</name> <value><string>Invalid API key or user account is not available</string></value> </member> <member> <name>APIErrorCode</name> <value><string>2</string></value> </member> </struct> </value>
Success Output Example
<value> <struct> <member> <name>Status</name> <value><string>Completed</string></value> </member> <member> <name>MediaURL1</name> <value><string>ID number of the image</string></value> </member> <member> <name>MediaURL2</name> <value><string>ID number of the image</string></value> </member> </struct> </value>
Campaign Functions
Subscriber List Functions
Subscriber Custom Field Functions
Subscriber List Segment Functions
Subscriber List Integration Functions
Subscriber Functions
- Subscriber.Add
- Subscriber.Get
- Subscribers.Get
- Subscriber.Update
- Subscriber.Delete
- Subscriber.Unsubscribe
Report Functions
- Report.Campaign.Advisory
- Report.Campaign.EmailPath
- Report.Campaign.OpensOverall
- Report.Campaign.OpensDetail
- Report.Campaign.ClicksOverall
- Report.Campaign.ClicksDetail
- Report.Campaign.UnsubscriptionsOverall
- Report.Campaign.UnsubscriptionsDetail
- Report.Campaign.BrowserViewsOverall
- Report.Campaign.BrowserViewsDetail
- Report.Campaign.ForwardsOverall
- Report.Campaign.ForwardsDetail
- Report.Campaign.BounceOverall
- Report.Campaign.BounceDetail
- Report.Campaign.SpamComplains
- Report.List.Advisory
- Report.List.Performance
- Report.List.BounceOverall
- Report.List.BounceDetails
- Report.List.Opens
- Report.List.Clicks
- Report.List.Forwards
- Report.List.BrowserViews
- Report.List.Activities
- Report.List.EmailServices
Media Library Functions
Chart Functions