-
Notifications
You must be signed in to change notification settings - Fork 27
Home
Welcome to the mod.io SDK wiki. This wiki explains how to setup, use and build mod.io SDK in your game or modding tool.
The SDK simplifies the mod.io integration, working as an intermediary. However, this can also be achieved by using the API directly or by using engine specific plugins, for more information visit our Getting Started guide.
The mod.io SDK provides all the functionality needed to access the mod.io backend. See the SDK Getting Started guide to start integrating the SDK on your project. Before diving into the SDK you should see if there is an existing plugin for your specific engine.
mod.io offers two different environments: testing and live. Testing is located in test.mod.io website it will only be visible for the developers, its meant to be a safe sandbox to prepare before going to the Live environment. The environment is set as a parameter in the Initialization method.
Users need to be authenticated to accomplish certain task such as creating, editing or subscribing to mods. mod.io offers a secure and easy authentication flow through email. You can find more information in User Authentication.
This are the steps to create a mod profile which can be found in the mod.io API and web. This function creates the mod profile as hidden, to go live you will need to Upload a Modfile.
- Initialize a modio::ModCreator, which will have the Mod's data.
- Fill the Mod's data using the modio::ModCreator functions.
- Call the function addMod by sending modio::ModCreator as a parameter.
- The callback Response Code should be
201 CREATED
.
In order for your mod to go live you will need to upload a modfile. Modfiles can't be edited, if you want to make a change upload a new one as a newer version.
- Initialize a modio::ModfileCreator, which will have the Modfile's data.
- Fill the Modfile's data using the modio::ModfileCreator functions.
- Call the function addModfile by sending modio::ModfileCreator as a parameter.
- The callback Response Code should be
201 CREATED
.
In case changes are wanted it follows a similar process as creating a mod.
- Initialize a modio::ModEditor, which will have the Mod's data.
- Fill the Mod's data to be edited using the modio::ModEditor functions.
- Call the function editMod by sending modio::ModEditor and the mod's id as a parameters.
- The callback Response Code should be
200 OK
.
You can browse Mod's data and filter the result so you retrieve only the mods you want.
- Initialize a modio::FilterCreator to define which would be the query criteria.
- Fill the filters data using the modio::FilterCreator function on the request you want to make.
- Call getMods by sending the modio::FilterCreator as parameter.
- The callback Response Code should be
200 OK
and a collection of Mods should be returned.
Additionally you can obtain the authenticated user's Mods using the getUserMods and getUserSubscriptions methods or a specific mod by using the getMod method.
The mod.io SDK features with a download queue and an installed mod list which gives you a variety of functions to handle local mods. See the Downloads documentation for details.
When a mod is updated through any method (web, API, SDK or plugin) it also updates itself locally. This will happen as long as the automatic option is enabled, additionally if a user subscribes to a mod it will be installed automatically.
Mods can not be permanently deleted but they can be archived so its only seen by the modder. You can delete a Mod by calling deleteMod by sending the mod ID as parameter.
Each method in the documentation displays an example but If you want a complete working example you could go to the official examples list.
Every callback returns an HTTP Response Code so you can check if there were any errors in your request, you could also review the log placed in .modio/log
for details.
If you want an integration with more features, you could see the complete method list in the Table of Contents.
- Home
- Table of Contents
- Getting Started
- SDK Methods
- Creators
- Editors
- Schemas
- modio::Avatar
- modio::Comment
- modio::Dependency
- modio::Download
- modio::Error
- modio::Filehash
- modio::Game
- modio::GameTagOption
- modio::Header
- modio::Icon
- modio::Image
- modio::InstalledMod
- modio::Logo
- modio::Media
- modio::MetadataKVP
- modio::Mod
- modio::ModEvent
- modio::Modfile
- modio::QueuedModDownload
- modio::QueuedModfileUpload
- modio::Rating
- modio::Response
- modio::Stats
- modio::Tag
- modio::User
- Debugging
- Constants
-
C Compatibility
- Methods
- Initialization, Process and Shutdown (C compatible)
- User Authentication (C compatible)
- Mods (C compatible)
- Modfiles (C compatible)
- Media (C compatible)
- Subscriptions (C compatible)
- Events (C compatible)
- Stats (C compatible)
- Tags (C compatible)
- Ratings (C compatible)
- Metadata KVP (C compatible)
- Dependencies (C compatible)
- Comments (C compatible)
- Reports (C compatible)
- Me (C compatible)
- Downloads (C compatible)
- Uploads (C compatible)
- Logs (C compatible)
- External Auth (C compatible)
- Configuration (C compatible)
- Creators
- Editors
- Schemas
- ModioAvatar
- ModioComment
- ModioDependency
- ModioDownload
- ModioError
- ModioFilehash
- ModioGame
- ModioGameTagOption
- ModioHeader
- ModioIcon
- ModioImage
- ModioInstalledMod
- ModioListNode
- ModioLogo
- ModioMedia
- ModioMetadataKVP
- ModioMod
- ModioModEvent
- ModioModfile
- ModioQueuedModDownload
- ModioQueuedModfileUpload
- ModioRating
- ModioResponse
- ModioStats
- ModioTag
- ModioUser
- Methods
- Building