sendspace API (1.2)

> Upload New File

Developer Guide

The sendspace Application Programming Interface (API) allows you to embed sendspace services in your applications, programs, or scripts, regardless of platform and programming language.
All communication with the sendspace API (1.2) assumes a UTF-8 encoding.

< Return to Method List

Method: auth.login

Description

Starts a session and returns user API method capabilities -- which features the given user can and cannot use.

Arguments
Name Mandatory Description
token Yes Received on create token
user_name Yes Registered email address
tokened_password Yes lowercase(md5(token+lowercase(md5(password)))) - md5 values should always be lowercase.
Returns

session_key to be sent with all method calls, user information, including the user account's capabilities. Only business users may receive chat_ready in response: 0/absent - instant messaging unavailable, 1 - only one user in the team, 2 – available and one or more team mate can be contacted.

Response

<result method="auth.login" status="ok">
    <session_key>XXXX</session_key>
    <user_name>Full name</user_name>
    <email>XXXX</email>
    <membership_type>pro/max/lite</membership_type>
    <membership_ends>timestamp/0=expired/-1=unlimited</membership_ends>
    <subscribed>0/1</subscribed>
    <capable_upload>0/1</capable_upload>
    <capable_download>0/1</capable_download>
    <capable_folders>0/1</capable_folders>
    <capable_files>0/1</capable_files>
    <chat_ready>0/1/2</chat_ready>
    <bandwidth_left>bytes/-1=unlimited</bandwidth_left>
    <diskspace_left>bytes/-1=unlimited</diskspace_left>
    <diskspace_used>bytes</diskspace_used>
    <points>0</points>   
</result>
                
Usage Example
                                           
http://api.sendspace.com/rest/?method=auth.login&token=57md654jwfl6l25idskzh8x3b5zwp46k&[email protected]&tokened_password=2cb501e4j86ef8ad17f6b26b90ee5764
                    
                
Possible Errors
Code Name Description
6 API_ERROR_SESSION_BAD Session expired or not found
8 API_ERROR_AUTHENTICATION_FAILURE Authentication error
11 API_ERROR_PERMISSION_DENIED Permission denied

Title

Alert