Link to Mod Share Mod Share

  Users Browse Upload Forums Log in

This page serves as a quick reference to the API that allows other applications to connect with Mod Share 4.

Get all users

URL: /api/getallusers
Parameters: none
Returns: colon-separated list of users
Example URL: modshare.futuresight.org/api/getallusers
Example response: jvvg:LS97:jacob

Get all projects

URL: /api/getallprojects
Parameters: none
Returns: colon-separated list of project IDs
Example URL: modshare.futuresight.org/api/getallprojects
Example response: 8:10:27:49

Get user information

URL: /api/getuserinfo
Parameters: user ID or username
Returns: id:username:status:num_projects:num_friends
Example URL: modshare.futuresight.org/api/getuserinfo/LS97
Example response: 4:LS97:normal:3:8

Get project information

URL: /api/getprojectinfo
Parameters: project ID
Returns: title:creation_timestamp:uploader_id:license:mod:description:views:downloads:loves
Example URL: modshare.futuresight.org/api/getprojectinfo/6
Example response: Hyperactive%20cat:1347730658:4:ms:insanity11::75:7:1
NOTE: The title and description are encoded as URL codes, so use PHP function rawurldecode() on those values.

Get project thumbnail

URL: /api/getprojectthumbnail
Parameters: project ID
Returns: raw PNG bytes of the project thumbnail
Example URL: modshare.futuresight.org/api/getprojectthumbnail/6
Example response:

Get all projects by user

URL: /api/getprojectsbyuser
Parameters: user ID or username
Returns: colon-separated list of project IDs
Example URL: modshare.futuresight.org/api/getprojectsbyuser/2
Example response: 26:45:55:61:68:82

Authenticate a user against their password on Mod Share

URL: /api/authenticate
Parameters: username/password
Returns: if success, "user_id:status". if failed, "false"
Example URL: modshare.futuresight.org/api/authenticate/LS97/password123
Example response: 4:banned