Documentation Bug: smugmug.accounts.getType
luke_church
Registered Users Posts: 507 Major grins
Issue:
Documentation implies 'string return type' API returns a struct:
Comment: I've had to purchase a Smugmug account specifically for this unit-testing, hence for obvious reasons, I'm only testing 'Standard' account featrues :
Can anyone confirm/reject effects for Power and Pro users? (I might be able to test Pro soon)
Documentation http://www.smugmug.com/hack/method-smugmug.accounts.getType
[php]
<?xml version="1.0"?>
<methodCall>
<methodName>smugmug.accounts.getType</methodName>
<params>
<param>
<value>
<string>97ac31554ddec6512fe8f334cd917fad</string>
</value>
</param>
</params>
</methodCall>
Header
<?xml version="1.0" encoding="iso-8859-1"?>
<methodResponse>
<params>
<param>
<value>
<struct>
<member>
<name>AccountType</name>
<value>
<string>Standard</string>
</value>
</member>
</struct>
</value>
</param>
</params>
</methodResponse>
[/php]
Workaround: I'm encapsulating the string in a struct.
All the best,
Luke
Documentation implies 'string return type' API returns a struct:
Comment: I've had to purchase a Smugmug account specifically for this unit-testing, hence for obvious reasons, I'm only testing 'Standard' account featrues :
Can anyone confirm/reject effects for Power and Pro users? (I might be able to test Pro soon)
Documentation http://www.smugmug.com/hack/method-smugmug.accounts.getType
XML chattering:String "AccountType"
- "Pro": Professional accounts
- "Power": Power User accounts
- "Standard": Standard accounts
[php]
<?xml version="1.0"?>
<methodCall>
<methodName>smugmug.accounts.getType</methodName>
<params>
<param>
<value>
<string>97ac31554ddec6512fe8f334cd917fad</string>
</value>
</param>
</params>
</methodCall>
Header
<?xml version="1.0" encoding="iso-8859-1"?>
<methodResponse>
<params>
<param>
<value>
<struct>
<member>
<name>AccountType</name>
<value>
<string>Standard</string>
</value>
</member>
</struct>
</value>
</param>
</params>
</methodResponse>
[/php]
Workaround: I'm encapsulating the string in a struct.
All the best,
Luke
0
Comments
I can confirm that the Power user works.
In regard to documentation vs. api, sometimes stuff doesn't work as advertised.
David
SmugMug API Developer
My Photos
Ah, I was considering a difference between the documentation and the API to be a bug. If it isn't, then someone please yell at me, and I won't post anymore. (And the moderator can feel free to take a big axe to the ones I have published)...
Seriously, if this isn't helpful, tell me and I'll stop it.
Luke
SmugSoftware: www.smugtools.com
i would say keep posting, don will get 'round to looking at them and then let you know if you're on the mark or not.... if i read his other post accurately, this is what he wanted isn't it?
Portfolio • Workshops • Facebook • Twitter
That's what I thought, hence why I'm doing it :
All the best,
Luke
SmugSoftware: www.smugtools.com
Same behaviour confirmed with XML-RPC 1.1.1 BETA
SmugSoftware: www.smugtools.com