Packagecom.initapp.webapis.pownce
Classpublic class PownceService
InheritancePownceService Inheritance com.adobe.webapis.URLLoaderBase

The Class is an ActionScript 3 Library for use against the Pownce V2.0 API

See also

http://initapp.com
http://pownce.pbwiki.com/API%20Documentation2-0
http://groups.google.com/group/pownceapi


Public Methods
 MethodDefined by
  
PownceService(apiKey:String, username:String = "", password:String = "")
Constructor.
PownceService
  
getFriendsFansAndFansOf(username:String, relationshipType:String, limit:int = 20, page:int = -1):void
Get an individual user's relationship data.
PownceService
  
getNote(noteID:int, showNoteReplies:Boolean = false, recipientLimit:Number = 0):void
Get a particular note by id.
PownceService
  
getNoteList(username:String, noteType:String = null, limit:int = 20, page:int = -1, sinceID:int = -1, noteSubsetType:String = null, setID:int = -1):void
Get a list of notes for a user.
PownceService
  
getNoteRecipientList(noteID:int, limit:int = 20, page:Number = -1):void
Get a list of recipients for a particular note.
PownceService
  
getProfile(username:String):void
Get an individual user's profile information.
PownceService
  
getPublicNoteList(noteType:String = null, limit:int = 20, page:int = -1, sinceID:int = -1):void
Get a list of all recent public notes.
PownceService
  
Get a the list of potential recipients for the authenticated user.
PownceService
  
postAFile(noteTo:String, file:FileReference, noteBody:String = "", usePro:Boolean = false):void
Post a note that contains a file.
PownceService
  
postALink(noteTo:String, url:String, noteBody:String = ""):void
Post a note that contains a link.
PownceService
  
postAMessage(noteTo:String, noteBody:String):void
Post a note that contains only a message.
PownceService
  
postAnEvent(noteTo:String, eventName:String, eventLocation:String, eventDate:Date, noteBody:String = ""):void
Post a note that contains an event.
PownceService
  
postAReply(replyTo:int, noteBody:String = "", stars:int = -1, rsvp:int = -1):void
Post a reply to a note.
PownceService
  
setAuth(username:String, password:String):void
Set the username and password to be used for authorization for this instance.
PownceService
  
verifyAuth(username:String, password:String):void
Check that authentication is successful.
PownceService
Events
 EventSummaryDefined by
    PownceService
    PownceService
    PownceService
    PownceService
    PownceService
    PownceService
    PownceService
    PownceService
    PownceService
    PownceService
    PownceService
    PownceService
    PownceService
Constructor detail
PownceService()constructor
public function PownceService(apiKey:String, username:String = "", password:String = "")

Constructor.

Parameters
apiKey:String — Application key provided by Pownce
 
username:String (default = "") — Optionally you can pass in username if you want to use an auth user at construction
 
password:String (default = "") — Optionally you can pass in the password for auth

See also

Method detail
getFriendsFansAndFansOf()method
public function getFriendsFansAndFansOf(username:String, relationshipType:String, limit:int = 20, page:int = -1):void

Get an individual user's relationship data.

Parameters
username:String — Username of a Pownce user.
 
relationshipType:String — Options are friends, fans, or fan_of. Use RelationshipType
 
limit:int (default = 20) — Optional. Limit the number of users returned. Default is 20 and max is 100.
 
page:int (default = -1) — Optional. Page number.
getNote()method 
public function getNote(noteID:int, showNoteReplies:Boolean = false, recipientLimit:Number = 0):void

Get a particular note by id.

Parameters
noteID:int — ID of the desired note.
 
showNoteReplies:Boolean (default = false) — Optional. By default the replies will not be included. To get the note with replies, use show_replies=true. Options are true or false.
 
recipientLimit:Number (default = 0) — Optional. Number or recipients listed. Default is 0 and max is 100.
getNoteList()method 
public function getNoteList(username:String, noteType:String = null, limit:int = 20, page:int = -1, sinceID:int = -1, noteSubsetType:String = null, setID:int = -1):void

Get a list of notes for a user.

Parameters
username:String — Filter the public notes by type. Options are messages, links, or events. Use NoteType
 
noteType:String (default = null) — Limit the number of notes returned. Default is 20 and max is 100.
 
limit:int (default = 20) — Page number.
 
page:int (default = -1) — Limit the notes returned to those greater than the specified note id.
 
sinceID:int (default = -1) — Get a subset of the authenticated user's note list. Options are notes (no replies), replies, sent, public, private, nonpublic (private and friends-only notes), and all. If no filter is specified, the notes will be returned according to the user's preferences.
 
noteSubsetType:String (default = null) — Filter the authenticated user's notes by a particular set. Only available for the authenticated user's own notes.
 
setID:int (default = -1)
getNoteRecipientList()method 
public function getNoteRecipientList(noteID:int, limit:int = 20, page:Number = -1):void

Get a list of recipients for a particular note.

Parameters
noteID:int — ID of the desired note.
 
limit:int (default = 20) — Optional. Limit the number of recipients returned. Default is 20 and max is 100.
 
page:Number (default = -1) — Optional. Number or recipients listed. Default is 0 and max is 100.
getProfile()method 
public function getProfile(username:String):void

Get an individual user's profile information.

Parameters
username:String — Username of a Pownce user.
getPublicNoteList()method 
public function getPublicNoteList(noteType:String = null, limit:int = 20, page:int = -1, sinceID:int = -1):void

Get a list of all recent public notes.

Parameters
noteType:String (default = null) — Filter the public notes by type. Options are messages, links, or events. Use NoteType
 
limit:int (default = 20) — Limit the number of notes returned. Default is 20 and max is 100.
 
page:int (default = -1) — Page number.
 
sinceID:int (default = -1) — Limit the notes returned to those greater than the specified note id.
getSendToList()method 
public function getSendToList():void

Get a the list of potential recipients for the authenticated user. Includes options for the public, all friends, sets, and individual friends.

postAFile()method 
public function postAFile(noteTo:String, file:FileReference, noteBody:String = "", usePro:Boolean = false):void

Post a note that contains a file.

Parameters
noteTo:String — The recipient(s) of the note. Options are all, friend_x, or set_x. Available options for the authenticated user can be found from the Send To List endpoint.
 
file:FileReference — The data of the file.
 
noteBody:String (default = "") — Optional. The main text body of the note.
 
usePro:Boolean (default = false) — Must be set to true if the user posting the file has a pro account.
postALink()method 
public function postALink(noteTo:String, url:String, noteBody:String = ""):void

Post a note that contains a link.

Parameters
noteTo:String — The recipient(s) of the note. Options are public, all, friend_x, or set_x. Available options for the authenticated user can be found from the Send To List endpoint.
 
url:String — full url for the link. Ex: http://pythong.org
 
noteBody:String (default = "") — The main text body of the note.
postAMessage()method 
public function postAMessage(noteTo:String, noteBody:String):void

Post a note that contains only a message.

Parameters
noteTo:String — The recipient(s) of the note. Options are public, all, friend_x, or set_x. Available options for the authenticated user can be found from the Send To List endpoint.
 
noteBody:String — The main text body of the note.
postAnEvent()method 
public function postAnEvent(noteTo:String, eventName:String, eventLocation:String, eventDate:Date, noteBody:String = ""):void

Post a note that contains an event.

Parameters
noteTo:String — The recipient(s) of the note. Options are public, all, friend_x, or set_x. Available options for the authenticated user can be found from the Send To List endpoint.
 
eventName:String — Name of the event.
 
eventLocation:String — Location of the event.
 
eventDate:Date — Date of the event.
 
noteBody:String (default = "") — Optional. The main text body of the note.
postAReply()method 
public function postAReply(replyTo:int, noteBody:String = "", stars:int = -1, rsvp:int = -1):void

Post a reply to a note.

Parameters
replyTo:int — The id of the note which this reply belongs to.
 
noteBody:String (default = "") — The main text body of the note.
 
stars:int (default = -1) — (messages, links, and files) The star rating the user gave the original note. Options are 1, 2, 3, 4, or 5. Use NoteStarType.
 
rsvp:int (default = -1) — (events) The rsvp reply for an event type note. Options are 1 Attending, 2 Busy Already, 3 Not Attending, 4 Running Late, 5 Bringing Friends, 6 Undecided, or 7 Wishing I Could Come! Use NoteRSVPType
setAuth()method 
public function setAuth(username:String, password:String):void

Set the username and password to be used for authorization for this instance.

Parameters
username:String — Pownce username
 
password:String — Pownce password
verifyAuth()method 
public function verifyAuth(username:String, password:String):void

Check that authentication is successful. This endpoint can be used to either test if the Http Basic auth header is correct. Also sets internal username and password through setAuth.

Parameters
username:String — Pownce username
 
password:String — Pownce password
Event detail
onGetFriendsFansFanOfevent 
Event object type: com.initapp.webapis.pownce.events.PownceResultEvent

onGetNoteevent  
Event object type: com.initapp.webapis.pownce.events.PownceResultEvent

onGetNoteListevent  
Event object type: com.initapp.webapis.pownce.events.PownceResultEvent

onGetNoteRecipientsListevent  
Event object type: com.initapp.webapis.pownce.events.PownceResultEvent

onGetProfileevent  
Event object type: com.initapp.webapis.pownce.events.PownceResultEvent

onGetPublicNoteListevent  
Event object type: com.initapp.webapis.pownce.events.PownceResultEvent

onGetSendToListevent  
Event object type: com.initapp.webapis.pownce.events.PownceResultEvent

onPostAFileevent  
Event object type: com.initapp.webapis.pownce.events.PownceResultEvent

onPostALinkevent  
Event object type: com.initapp.webapis.pownce.events.PownceResultEvent

onPostAMessageevent  
Event object type: com.initapp.webapis.pownce.events.PownceResultEvent

onPostAnEventevent  
Event object type: com.initapp.webapis.pownce.events.PownceResultEvent

onPostAReplyevent  
Event object type: com.initapp.webapis.pownce.events.PownceResultEvent

onVerifyAuthevent  
Event object type: com.initapp.webapis.pownce.events.PownceResultEvent