create
create
Creates a new session.
Parameters
Name | Description |
node_id optional | Node ID |
user_id optional | User ID |
username optional | Username |
email optional | |
agent optional | Browser Agent |
ip optional | IP Address |
expires optional | Expiration (Seconds) |
session_data optional | Session Data |
anonymous optional | Anonymous Session |
use_access_token optional | Use Access Token (in place of CoreU/CoreX) |
Request Syntax
https://services.onesite.com/1/session/create.json?node_id=188234&user_id=229928503&ip=127.0.0.1&agent=Mozilla/5.0 (Macintosh; Intel Mac OS X 10.7; rv:10.0.2) Gecko/20100101 Firefox/10.0.2&devkey=[devkey] |
JSON Response
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 |
{ "code":100, "message":"Session generated.", "content":{ "session":{ "CoreU":"1c7852eae9d551a8707e3327a07bc5cd", "CoreX":"b110b6aee408077be33a8a85f5559981", "Expires":1549059418, "State":"valid", "RemoteIP":"127.0.0.1", "Agent":"Mozilla/5.0 (Macintosh; Intel Mac OS X 10.7; rv:10.0.2) Gecko/20100101 Firefox/10.0.2", "User":{ "UserID":229928503, "Username":"onesitedemo", "Email":"not_an_email@onesite.com", "Site":{ "SiteID":234714047, "Subdir":"onedemo", "URL":"http://www.onesitedemo.com/onedemo" }, "Avatar":"http://services.onesite.com/resources/images/unisex_v4b.gif?ver=13.06.21", "Name":"ONEsite", "AccountStatus":"good-standing", "DateCreated":1547859723, "Profile":{ "Birthday":852098400, "FirstName":"ONEsite", "LastName":"", "Gender":"Unspecified", "Address":"14000 Quail Springs Pkwy", "Address2":"Suite 3600", "City":"Oklahoma City", "State":"OK", "Zip":"73134", "Location":"", "Timezone":0, "Quote":"", "Language":"en_US" }, "Preferences":{ "BirthdayDisplay":"private", "FriendshipApproval":0, "CommentsApproval":2, "MessagePrivacy":0, "EmailNotification":"ongoing", "Searchable":true, "ShowOnlineStatus":true }, "ExternalAccounts":[ { "ProviderName":"facebook", "UserIdentifier":"100003605854098", "AccessToken":"AAABiJIiZCZCFsBAFoxzERj96ATjIFG64wl85e1Q80yDeombreCD3vMDdWVg9uKm24a04SZCbUkhnOv7M2Q7ZBXqdVvtQrvFwBNcyvXJ7UwZDZD" }, { "ProviderName":"twitter", "UserIdentifier":"515927988", "AccessToken":"oauth_token%3D515927988-BC2VDqFfeKM1Y6ZdxSqeVJrsBDv1Eh0MoZl61bM%26oauth_token_secret%3D6w8CG8WUZwcrsDLfeP1BxdtriE9BpvIhQ2m09BMuK04%26user_id%3D515927988%26screen_name%3D1DemoUser" } ], "Tiers":[ 1 ] } } } } |
Service Information
Service | session |
Method | create |
Type | REST |
Response Types | JSON, XML |