Game concepts
Resting and using items

Rest

Resting allows you to fully recover your hit points. The cooldown is 1 second per 1% of missing HP (rounded up), with a minimum of 3 seconds.

For example, if your character has lost 50% of their HP, the cooldown will be 50 seconds.

Rest always restores all your HP in a single action — there is no partial heal.

You can rest by using this POST request.

cURL
curl --request POST \
  --url https://api.artifactsmmo.com/my/{name}/action/rest \
  --header 'Accept: application/json' \
  --header 'Authorization: Bearer INSERT_YOUR_TOKEN_HERE' \
  --header 'Content-Type: application/json' \
Javascript
const url = 'https://api.artifactsmmo.com/my/{name}/action/rest';
const options = {
  method: 'POST',
  headers: {
    'Content-Type': 'application/json',
    Accept: 'application/json',
    Authorization: 'Bearer INSERT_YOUR_TOKEN_HERE'
  }
 
};
  
try {
  const response = await fetch(url, options);
  const data = await response.json();
  console.log(data);
} catch (error) {
  console.error(error);
}

View the API Reference (opens in a new tab)

Using items

You can use all items categorized as consumable. You can see the list of items on our website (opens in a new tab) or use an API request (opens in a new tab).

KeywordCondition
HealRestores x health points to your character.
GoldAdds x gold to your character's inventory.
TeleportTeleport to Map ID: x

To use an item, your character must meet all the item's conditions. An item's conditions can use any character variable and an operator such as gt, lt, or eq.

Using a consumable has a fixed cooldown of 3 seconds, regardless of the quantity used. Heal effects are capped at your maximum HP — you cannot overheal.

For example, the Cooked Beef (opens in a new tab) requires your character to be above level 4.

JSON
{
...
  "conditions": [
    {
      "code": "level",
      "operator": "gt",
      "value": 4
    }
  ],
....

You can use an item by using this POST request.

cURL
curl --request POST \
  --url https://api.artifactsmmo.com/my/{name}/action/use \
  --header 'Accept: application/json' \
  --header 'Authorization: Bearer INSERT_YOUR_TOKEN_HERE' \
  --header 'Content-Type: application/json' \
  --data '{
  "code": "string",
  "quantity": 1
}'
Javascript
const url = 'https://api.artifactsmmo.com/my/{name}/action/use';
const options = {
  method: 'POST',
  headers: {
    'Content-Type': 'application/json',
    Accept: 'application/json',
    Authorization: 'Bearer INSERT_YOUR_TOKEN_HERE'
  },
    body: '{"code":"string","quantity":1}'
 
};
  
try {
  const response = await fetch(url, options);
  const data = await response.json();
  console.log(data);
} catch (error) {
  console.error(error);
}
FieldDescription
codeThe consumable item code to use.
quantityNumber of items to use.

View the API Reference (opens in a new tab)