Attain API

Version 2.0.0

Resources:

widgetMember PATCH POST GET /widgets/{widgetid}

get
Get
required numeric directoryid
required string token
optional numeric widgetid (default: 0)
post
Post
required numeric widgetid
required numeric directoryid
required string widgetkey
required string baseurl
optional numeric usesitecss (default: 0)
optional string headlinecolour (default: #003c72)
optional string headlinefont (default: "")
optional string leadcolour (default: #3777bc)
optional string leadfont (default: "")
optional string bodycolour (default: #000000)
optional string bodyfont (default: "")
optional string view (default: grid)
optional numeric period (default: 6)
patch
Patch
required numeric widgetid (default: 0)
required numeric directoryid
optional string baseurl
optional numeric usesitecss
optional string headlinecolour
optional string headlinefont
optional string leadcolour
optional string leadfont
optional string bodycolour
optional string bodyfont
optional numeric period
optional string view
getWidgetData
setSchoolData
required any schoolData
setWidgetData
required any widgetData
getSchoolData

widgetCollection GET /widgets/

get
Get
required string token
getWidgetData
setMemberData
required any memberData
setWidgetData
required any widgetData
getMemberData

userMember POST GET /users/{memberid}

get
Get
required numeric memberid (default: 0)
required string token
post
Post
required numeric memberid (default: 0)
required string token
required string realname
required string position
optional string biography (default: "")
optional string signature (default: "")
required string email
required string pword (default: "")
leave alone if blank, i.e. don't change the password
optional string permission (default: Contributor)
optional string directoryid (default: "")
The school(s) the member/user should be linked to
setMemberData
required any memberData
setMedialibraryData
required any medialibraryData
getMedialibraryData
setAuth
required any auth
getMemberData
getAuth

userCollection GET /users

get
Get
required string token
optional numeric limit (default: 10)
optional numeric offset (default: 10)
optional numeric page (default: 1)
optional numeric per_page (default: 10)
optional string permission (default: "")
setMemberData
required any memberData
getMemberData

twitterConfirm GET /twitter/confirm/{smid}

get
Get AuthURL
required string token

twitterAuthorise GET /twitter/authorize

get
Get
optional any oauth_verifier
optional any denied
optional numeric smid (default: 0)
This should be in the query string of callback url
setSchoolData
required any schoolData
getSchoolData

twitterAuth GET /twitter/auth/{smid}

get
Get AuthURL : NB, removed CSRF
required string token
required numeric smid
setSchoolData
required any schoolData
getSchoolData

tweetNews POST /tweet/news/{newsid}

post
Post
required string token
required numeric newsid
required numeric smid
required string tweet
required numeric mediaid (default: 0)
optional string account (default: attain)
optional boolean checkHeader (default: false)
setSchoolData
required any schoolData
setMemberData
required any memberData
setMedialibraryData
required any medialibraryData
getMedialibraryData
getMemberData
getSchoolData

timelineCollection GET /timeline/

get
Get
required string token
optional numeric limit (default: 10)
optional numeric offset (default: 0)
optional numeric page (default: 1)
optional numeric per_page (default: 10)
optional numeric categoryid (default: 0)
setMemberData
required any memberData
getMemberData
setNewsData
required any newsData
getNewsData

storyMember DELETE PATCH POST GET /stories/{newsid}

get
Get
required numeric newsid
required string token
post
Post
optional numeric newsid (default: 0)
required string token
optional any newsdate (default: [runtime expression])
optional numeric categoryid (default: 0)
required string directoryid
required string headline
optional string shorttitle (default: "")
required string detail
optional string pressheadline (default: "")
optional string presssummary (default: "")
optional string pressrelease (default: "")
optional string noteforeditor (default: "")
optional string coveringmsg (default: "")
optional string breakoutquote (default: "")
optional string lead (default: "")
optional string transloadit (default: "")
optional numeric isapproved (default: 0)
optional numeric publish_attain (default: 0)
optional numeric publish_feed (default: 0)
optional numeric featured (default: 0)
optional numeric istweeted (default: 0)
optional numeric reviewed (default: 0)
optional string editorchoice (default: "")
patch
patch
required numeric newsid
required string token
delete
delete
required numeric newsid
setMemberData
required any memberData
getApplenews
setMedialibraryData
required any medialibraryData
getEmailService
getNewsData
getDirectoryData
setUtils
required any utils
getMedialibraryData
getUtils
getMemberData
setEmailService
required any emailService
setNewsData
required any newsData
setApplenews
required any applenews
setDirectoryData
required any directoryData

storyCollection GET /stories/

get
Get
required string token
optional numeric limit (default: 10)
optional numeric offset (default: 0)
optional numeric page (default: 1)
optional numeric per_page (default: 10)
optional numeric categoryid (default: 0)
optional numeric search (default: 0)
setMemberData
required any memberData
getMemberData
setNewsData
required any newsData
getNewsData

myattainStats GET /statistics/

get
get
required string token
setMemberData
required any memberData
getMemberData
setNewsData
required any newsData
getNewsData

socialMediaMember POST GET /social/accounts/{smid}

get
Get
required numeric smid
required string token
post
post
optional numeric smid (default: 0)
required string token
required string screenname
optional string mediatype (default: Twitter)
optional string directoryid (default: "")
setMemberData
required any memberData
setSchoolData
required any schoolData
getMemberData
getSchoolData

socialMediaCollection GET /social/accounts

get
Get
required string token
setMemberData
required any memberData
setSchoolData
required any schoolData
getMemberData
getSchoolData

schoolMember PATCH PUT POST GET /schools/{directoryid}

get
Get
required numeric directoryid
required string token
patch
patch
required numeric directoryid
required string token
post
post
required numeric directoryid
required string token
required string organisation
optional string address1 (default: "")
optional string address2 (default: "")
optional string address3 (default: "")
optional string postcode (default: "")
optional string website (default: "")
optional string introtext (default: "")
optional string description (default: "")
optional string yearfounded (default: "")
optional string charityregno (default: "")
optional string isinumber (default: "")
optional numeric relaffid (default: 0)
optional string tel (default: "")
optional string contactemail (default: "")
optional string boysage_start (default: "")
decimal
optional string boysage_end (default: "")
decimal
optional string day_boys (default: "")
numeric
optional string boysboard_start (default: "")
decimal
optional string boysboard_end (default: "")
decimal
optional string boarding_boys (default: "")
numeric
optional string girlsage_start (default: "")
decimal
optional string girlsage_end (default: "")
decimal
optional string day_girls (default: "")
numeric
optional string girlsboard_start (default: "")
decimal
optional string girlsboard_end (default: "")
decimal
optional string boarding_girls (default: "")
numeric
optional string sixthform (default: "")
numeric
optional string day_fees_from (default: "")
decimal
optional string day_fees_to (default: "")
decimal
optional string boarding_fees_from (default: "")
decimal
optional string boarding_fees_to (default: "")
decimal
optional string fees_notes (default: "")
optional string schol_burs (default: "")
optional numeric acad_sel (default: 0)
optional string admission_notes (default: "")
optional string video_embed (default: "")
put
Put
required numeric directoryid
required string token
setMemberData
required any memberData
setSchoolData
required any schoolData
setMedialibraryData
required any medialibraryData
getMedialibraryData
getMemberData
setEmailService
required any emailService
getEmailService
getSchoolData

schoolCollection GET /schools

get
Get
required string token
optional numeric newsid (default: 0)
setMemberData
required any memberData
setSchoolData
required any schoolData
getMemberData
getSchoolData

registerMember POST GET /registration/{regid}

get
Registration Checker - check to see if the entered email is registered already AND check the email domain for existing plan 2,3.
required string email
post
Registration Notification
required string name
required string position
required string school
required string email
setMemberData
required any memberData
setAuth
required any auth
getMemberData
setEmailService
required any emailService
getAuth
getEmailService

publicWidgetCollection GET /public/widget/{widgetkey}

get
get
required string widgetkey
optional numeric page (default: 1)
optional numeric per_page (default: 10)
getWidgetData
setWidgetData
required any widgetData
setNewsData
required any newsData
getNewsData

publicStoryMember GET /public/news/{newsid}

get
Get
required numeric newsid (default: 0)
setNewsData
required any newsData
getNewsData

publicISCWidgetCollection GET /public/iscwidget/{isccode}

get
get
required string isccode
optional numeric page (default: 1)
optional numeric per_page (default: 4)
setSchoolData
required any schoolData
setNewsData
required any newsData
getSchoolData
getNewsData

publicFeedCollection GET /public/feed/{apikey}

get
get
required string apikey
optional numeric page (default: 1)
optional numeric per_page (default: 10)
getFeedData
setNewsData
required any newsData
setFeedData
required any feedData
getNewsData

presstagsMember DELETE POST GET /presstags/{tagid}

get
get
required numeric tagid
post
post
required numeric tagid
required string tagname
required string token
delete
delete
required numeric tagid
getPresstagsData
setMemberData
required any memberData
setPresscontactData
required any presscontactData
getMemberData
getPresscontactData
setPresstagsData
required any presstagsData

presstagsCollection GET /presstags

get
get
required string token
getPresstagsData
setPresstagsData
required any presstagsData

presscontactMember DELETE POST GET /presscontacts/{presscontactid}

get
get
required numeric presscontactid
required string token
post
post
required numeric presscontactid (default: 0)
required string token
required string title
required string firstname
required string lastname
required string email
required string position
optional string organisation (default: "")
optional string mediatitle (default: "")
optional string programme (default: "")
optional string directoryid (default: "")
admins only
optional string tags (default: "")
delete
delete
required numeric presscontactid
required string token
setMemberData
required any memberData
setPresscontactData
required any presscontactData
getMemberData
getPresscontactData

presscontactCollection GET /presscontacts

get
get
required string token
setMemberData
required any memberData
setPresscontactData
required any presscontactData
getMemberData
getPresscontactData

pressRelease POST /press/release/{newsid}

post
send release
required string presscontactids
setMemberData
required any memberData
setPresscontactData
required any presscontactData
getMemberData
getPresscontactData
setEmailService
required any emailService
setNewsData
required any newsData
getEmailService
getNewsData

pressPreview POST /press/preview/{newsid}

post
send preview release
required numeric newsid
required string token
sendPreview
send Preview
required numeric newsid
required string token
setMemberData
required any memberData
getMemberData
setEmailService
required any emailService
setNewsData
required any newsData
getEmailService
getNewsData

blogPostMember DELETE PATCH POST GET /posts/{postid}

get
Get
required numeric postid
required string token
optional string permission (default: "")
post
Post
required numeric postid
required string token
optional any postdate (default: [runtime expression])
optional numeric categoryid (default: 0)
optional numeric directoryid (default: 0)
optional numeric authorid (default: 0)
optional string tags (default: "")
optional string posttitle (default: "")
optional string detail (default: "")
optional string breakoutquote (default: "")
optional string standfirst (default: "")
optional numeric isapproved (default: 0)
patch
Patch
required numeric postid
required string token
delete
Delete
required numeric postid
getBlogData
setBlogData
required any blogData
getDirectoryData
setUtils
required any utils
getUtils
setAuth
required any auth
setEmailService
required any emailService
getAuth
getEmailService
setDirectoryData
required any directoryData
get
Get
required string token
optional numeric limit (default: 10)
optional numeric offset (default: 0)
optional numeric page (default: 1)
optional numeric per_page (default: 10)
optional numeric categoryid (default: 0)
getBlogData
setBlogData
required any blogData
setMemberData
required any memberData
getMemberData

planCollection GET /plans

get
get
required string token
setPlansData
required any plansData
getPlansData

photoCropper POST /photo/crop/{mediaid}

post
Crop it
required numeric mediaid
required string token
optional string cropoption (default: crop)
required numeric x1
required numeric x2
required numeric y1
required numeric y2
setUtils
required any utils
getTransloadit
setMemberData
required any memberData
setTransloadit
required any transloadit
setMedialibraryData
required any medialibraryData
getMedialibraryData
getUtils
getMemberData

password POST /password/

post
Password reset: looks up member, generates random 8 char string and emails
required string email
setMemberData
required any memberData
setAuth
required any auth
getMemberData
setEmailService
required any emailService
getAuth
getEmailService

newstagsMember DELETE POST GET /newstags/{tagid}

get
get
required numeric tagid
post
post
required numeric tagid
required string tagname
required string token
delete
delete
required numeric tagid
setMemberData
required any memberData
getMemberData
setNewstagsData
required any newstagsData
getNewstagsData

newstagsCollection GET /newstags

get
get
required string token
setNewstagsData
required any newstagsData
getNewstagsData

newscategoriesMember GET /newscategories/{categoryid}

get
get
required string token
required numeric categoryid
getNewscategoryData
setNewscategoryData
required any newscategoryData

newscategoriesCollection GET /newscategories

get
get
required string token
getNewscategoryData
setNewscategoryData
required any newscategoryData

mediaMember DELETE GET /media/{mediaid}

get
Get
required numeric mediaid
required string token
delete
Delete
required numeric mediaid
required string token
setMemberData
required any memberData
setMedialibraryData
required any medialibraryData
getMedialibraryData
getMemberData

mediaCollection POST GET /media

get
Get
required string token
optional numeric directoryid (default: 0)
optional numeric offset (default: 0)
optional numeric limit (default: 25)
post
Post
required string token
required numeric directoryid
optional string transloadit
optional numeric offset (default: 0)
optional numeric limit (default: 25)
setMemberData
required any memberData
setMedialibraryData
required any medialibraryData
getMedialibraryData
getMemberData

magazineDistribution DELETE POST GET /magazine/distribution

get
Read
required string token
post
Create
required numeric directoryid
required string token
delete
Delete
required numeric directoryid
required string token

digitalEditionRelease POST /magazine/digital/release

post
Preview
required string token
required numeric directoryid

digitalEditionPreview POST /magazine/digital/preview

post
Preview
required string token
required string email
optional string coveringmessage

digitalEdition POST GET /magazine/digital

get
get
required string token
post
post
required string token
required numeric messageid
required string coveringmessage (default:

Dear {{firstname}},

I am please to enclose a copy of the latest Attain.

{{headname}}

)
setDigitalService
required any digitalService
setMemberData
required any memberData
getMemberData
getDigitalService

iapsNewsCollection GET /iaps/news/{apikey}

get
This really should be a call to Attain News with directoryid 566
required string apikey
optional numeric page (default: 1)
optional numeric per_page (default: 10)
optional numeric directoryid (default: 566)
optional numeric newsid (default: 0)
optional string filter (default: iapsonly)
optional string category (default: "")
optional numeric featured (default: 1)
setNewsData
required any newsData
getNewsData

hello GET /hello

get

feedExport GET /feeds/export

get
Get
required string token
getFeedData
setFeedData
required any feedData

feedMember DELETE POST GET /feeds/{feedid}

get
Get
required numeric feedid
required string token
post
Post
required numeric feedid
required string token
required numeric directoryid
required string feedname
optional string newstypeid (default: 1)
optional string categoryid (default: "")
optional string tagid (default: "")
deprecated
delete
Delete
required numeric feedid
required string token
getFeedData
setMemberData
required any memberData
getMemberData
setFeedData
required any feedData

feedCollection GET /feeds

get
Get
required string token
optional numeric limit (default: 10)
optional numeric offset (default: 0)
optional numeric page (default: 1)
optional numeric per_page (default: 10)
getFeedData
setFeedData
required any feedData

environment GET /environment

get

emailTest POST GET /emailtest

get
post

emailAttainEditor POST /editor/{requesttype}

post
Post
required numeric newsid
required string token
required string requesttype (default: editrequest)
setMemberData
required any memberData
getMemberData
setEmailService
required any emailService
setNewsData
required any newsData
getEmailService
getNewsData

eventMember DELETE POST GET /calevents/{calendarid}

get
get
required numeric calendarid (default: 0)
required string token
post
post
required numeric calendarid
required string token
required numeric directoryid
required string eventtitle
required string eventdetail
required any eventstart
required any eventstarttime
required any eventendtime
optional numeric attainprint (default: 0)
delete
delete
required numeric calendarid
required string token
setUtils
required any utils
setMemberData
required any memberData
getUtils
getMemberData
setEventsData
required any eventsData
getEventsData

eventCollection GET /calevents

get
Preview
required string token
optional numeric limit (default: 25)
optional numeric offset (default: 0)
optional numeric page (default: 1)
optional numeric per_page (default: 25)
setUtils
required any utils
setMemberData
required any memberData
getUtils
getMemberData
setEventsData
required any eventsData
getEventsData

blogtagsMember DELETE POST GET /blogtags/{tagid}

get
Get
required numeric tagid
post
Post
required numeric tagid
required string tagname
required string token
delete
Delete
required numeric tagid
getDirectoryData
setBlogtagsData
required any blogtagsData
getBlogtagsData
setDirectoryData
required any directoryData

blogtagsCollection GET /blogtags

get
Get
required string token
setBlogtagsData
required any blogtagsData
setMemberData
required any memberData
getMemberData
getBlogtagsData

blogcategoriesCollection GET /blogcategories

get
Get
required string token
getBlogData
setBlogData
required any blogData

authorMember DELETE POST GET /authors/{authorid}

get
Get
required numeric authorid
required string token
post
Post
required numeric authorid
required string token
required string title
required string firstname
required string lastname
required string summary
optional string profile (default: "")
optional string footnote (default: "")
delete
required numeric authorid
required string token
getBlogData
setBlogData
required any blogData
getDirectoryData
setMedialibraryData
required any medialibraryData
getMedialibraryData
setAuth
required any auth
getAuth
setDirectoryData
required any directoryData

authorCollection GET /authors

get
Get
required string token
getBlogData
setBlogData
required any blogData

authenticate DELETE POST GET /authenticate

get
Read current authentication from token
post
Main Login
required string email
required string password
delete
Logout
options
Options
setAuth
required any auth
getAuth

attainEventCollection GET /attain/opendays/{apikey}

get
Get
optional numeric limit (default: 25)
optional numeric offset (default: 0)
optional numeric page (default: 1)
optional numeric per_page (default: 25)
optional numeric directoryid (default: 0)
optional string region (default: "")
setEventsData
required any eventsData
getEventsData

attainNewsMember GET /attain/news/story/{apikey}/{newsid}

get
Get
required numeric newsid
setNewsData
required any newsData
getNewsData

attainNewsCollection GET /attain/news/{apikey}

get
Get
required string apikey
optional numeric page (default: 1)
optional numeric per_page (default: 10)
optional numeric directoryid (default: 0)
optional numeric newsid (default: 0)
optional string filter (default: "")
optional string category (default: "")
setNewsData
required any newsData
getNewsData

attainDirectoryMember GET /attain/directory/{apikey}/{directoryid}

get
Get
required numeric directoryid
getDirectoryData
setDirectoryData
required any directoryData

attainDirectoryCollection GET /attain/directory/{apikey}

get
Get
optional string postcode
optional numeric categoryid
optional string child
optional numeric distance
optional numeric lat
optional numeric lon
optional string sterm
optional string region
optional string orgtype
setUtils
required any utils
getDirectoryData
getUtils
setDirectoryData
required any directoryData

attainBlogPostMember GET /attain/blog/posts/{apikey}/{postid}

get
Get
required string apikey
optional numeric postid (default: 0)
getBlogData
setBlogData
required any blogData

attainBlogPostsCollection GET /attain/blog/posts/{apikey}

get
Get
required string apikey
optional numeric page (default: 1)
optional numeric per_page (default: 10)
optional string filter (default: "")
optional numeric categoryid (default: 0)
getBlogData
setBlogData
required any blogData

appleNewsTest GET /apple/{newsid}

get
required numeric newsid
required string token
setUtils
required any utils
setMemberData
required any memberData
getApplenews
getUtils
getMemberData
setNewsData
required any newsData
setApplenews
required any applenews
getNewsData

Resources are listed in matching order. From top to bottom, the first URI to match the request is used.