Tell me more ×
SmugMug Stack Exchange is a question and answer site for SmugMug developers and end users. It's 100% free, no registration required.

There are several API requests that have loads of data available in the response (smugmug.albums.get for instance) but by default the info returned is minimal and the heavy=true option returns too much info. Is there some way to get back a subset of information from these requests?

share|improve this question
1  
I want to vote this up twice, great question Shizam. – dpollitt Feb 4 '12 at 5:23
Hah, thanks, I dunno if this has ever been documented before :) – Shizam Feb 4 '12 at 21:39

1 Answer

up vote 11 down vote accepted

The 'Extras' argument is what you should use to get specific information back from an API request, its a comma delimited list of values you're interested in. For a smugmug.albums.get request where you want to know the 'Keywords' and 'Public' value you would add the Extras argument as:

...&Extras=Keywords,Public

You can pass in any values you find in the heavy result, here is an Example Request.

And a snapshot of what a piece of that response looks like:

{
  "stat": "ok",
  "method": "smugmug.albums.get",
  "Albums": [
    {
      "id": 5363890,
      "Key": "GxmcTJ",
      "Category": {
        "id": 960,
        "Name": "SmugMug"
      },
      "Keywords": "",
      "Public": true,
      "SubCategory": {
        "id": 59297,
        "Name": "Marketing shots"
      },
      "Title": "SmugMug homepage slide show"
    },
    {
      "id": 4318757,
      "Key": "fqH3fM",
      "Category": {
        "id": 960,
        "Name": "SmugMug"
      },
      "Keywords": "",
      "Public": true,
      "SubCategory": {
        "id": 59297,
        "Name": "Marketing shots"
      },
      "Title": "SmugMug videos"
    },
...
share|improve this answer

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.