SANDBOX — this is a test environment. No servers are actually deployed and no real payments are charged.
✓ VerifiedLibraries & compatibility

Temporal API

by CyberRat2 · for Minecraft

Temporal API is the library for Team Temporal mods, other projects may use it as well.

152KDownloads
2 yr agoLast updated
LicenseRef-All-Rights-ReservedLicense
ForgeLoaders

About Temporal API

From Modrinth

Temporal API is the library for Team Temporal mods, other projects may use it as well.

Temporal API is the official library for the Team Temporal mods other projects and modders and modpack creators may use it for their projects as much as they like.

The main goal of this mod is to make creating mods easier and more flexible!

For working with our library you need to go to build.gradle and add this:

repositories {
    maven {
        url "https://cursemaven.com"
    }
}

dependencies {
    implementation fg.deobf("curse.maven:temporalapi-970291:<file-id>")
    
    ...
}

You need to replace <file id> with file id that can be found in the end of link of needed version of the mod file.

The library for current state adds

factories, tag utils, creative tab utils, trading with villagers and wanderers customizer, world features utils, item properties utils, fov modifier etc Factory and Extensions Factories are used to create RegistryObject objects and make their creation a lot easier.

For using ItemFactory from API you need to create ItemFactoryFacade class like here:

public class ModItemFactoryFacade extends ItemFactory {
    public ModItemFactoryFacade() {
        super(ModItems.ITEMS);
    }
}

Also you can extend your Factory Facade with Extensions from API or create your own Extension.

Here are 2 examples of using SwordExtension (with this Extension creating of Sword becomes a lot easier):

Like this:

public class ModItemFactoryFacade extends ItemFactory implements SwordExtension {
    public ModItemFactoryFacade() {
        super(ModItems.ITEMS);
    }
}

Or like this:

public class ModItemFactoryFacade extends ItemFactory implements SwordExtension {
    public ModItemFactoryFacade() {
        super(ModItems.ITEMS);
    }

    public RegistryObject<SwordItem> createSword(String name, Object... args) {
        return SwordExtension.super.createSword(name, this, args);
    }

    public RegistryObject<? extends SwordItem> createSword(String name, Supplier<? extends SwordItem> tTypedSupplier) {
        return SwordExtension.super.createSword(name, this, tTypedSupplier);
    }
}

So what about creating our object using this Facade class:

public class ModItems {
    public static final DeferredRegister<Item> ITEMS = DeferredRegister.create(Registries.ITEM, "MOD_ID");
    public static final ModItemFactoryFacade ITEM_FACTORY = new ModItemFactoryFacade();

    public static final RegistryObject<Item> MY_ITEM_1 = ITEM_FACTORY.create("my_item_1");
    public static final RegistryObject<Item> MY_ITEM_2 = ITEM_FACTORY.create("my_item_2", new Item.Properties());
    public static final RegistryObject<Item> MY_ITEM_3 = ITEM_FACTORY.create("my_item_3", () -> new Item(new Item.Properties()));

    //First example of creating Facade object from up
    public static final RegistryObject<SwordItem> MY_SWORD_1 = ITEM_FACTORY.createSword("my_sword_1", ITEM_FACTORY, Tiers.STONE, 3, -2.4F);
    public static final RegistryObject<? extends SwordItem> MY_SWORD_2 = ITEM_FACTORY.createSword("my_sword_2", ITEM_FACTORY, () -> new SwordItem(Tiers.STONE, 3, -2.4F, new Item.Properties()));


    //Second example of creating Facade object from up
    public static final RegistryObject<SwordItem> MY_SWORD_3 = ITEM_FACTORY.createSword("my_sword_3", Tiers.STONE, 3, -2.4F);
    public static final RegistryObject<? extends SwordItem> MY_SWORD_4 = ITEM_FACTORY.createSword("my_sword_4", () -> new SwordItem(Tiers.STONE, 3, -2.4F, new Item.Properties()));
}

Now lets's look on args... array. It is an array of arguments for creating an object (Will be changed in future for better readability).

Currently available Factories and extensions:

ItemFactory (ArrowExtension, BowExtension, BowlExtension, MusicDiscExtension, SmithingTemplateExtension, SwordExtension, AxeExtension, PickaxeExtension, ShovelExtension, HoeExtension)
BlockFactory (BushExtension, FlowerExtension, PottedFlowerExtension)
ParticleFactory
EffectFactory
PaintingFactory
PotionFactory
SoundEventFactory
CreativeTabFactory
EntityFactory
Tag Utils
Tag utils focus on tag creating and making using tags easier.

For example if you want to create item tag you need to use ItemTagFactory:

public class MyItemTags {
    public static final TagFactory<Item> TAG_FACTORY = new ItemTagFactory("MY_MOD_ID");

    public static final TagKey<Item> MY_TAG = TAG_FACTORY.createTag("my_tag");
}
Creative Tab Utils
Creative tab utils are used to add items to Creative Tab that you need.

Firstly we need to go to our class that subscribed for mod events and add this function (inner part of method is just example):

@SubscribeEvent
public void addCreativeTabs(BuildCreativeModeTabContentsEvent event) {
    new SimpleTabAdder(event)
            .addAllToTab(CreativeModeTabs.INGREDIENTS, ModItems.MY_ITEM_1, ModItems.MY_ITEM_2, ModItems.MY_ITEM_3)
            .addAllToTab(CreativeModeTabs.COMBAT, ModItems.MY_SWORD_1, ModItems.MY_SWORD_2, ModItems.MY_SWORD_3);
}

Trading with Villagers and Wanderers Utils TemporalAPI makes trading a lot easier. Here is an example of it:

public static final TradeCustomizer tradeCustomizer = new SimpleTradeCustomizer();

@SubscribeEvent
public void customizeTradesWithVillagers(VillagerTradesEvent event) {
    tradeCustomizer.customize(event, new VillagerTrade(
            new TradingItemHolder(Items.ANDESITE, 2),
            new TradingItemHolder(Items.EMERALD, 3),
            new VillagerTradeDescription(
                    VillagerProfession.ARMORER, 1, 5, 5, 0.5f
            )
    ));
}

@SubscribeEvent
public void customizeTradesWithWanderers(WandererTradesEvent event) {
    tradeCustomizer.customize(event, new WandererTrade(
            new TradingItemHolder(Items.ANDESITE, 2),
            new TradingItemHolder(Items.EMERALD, 3),
            new WandererTradeDescription(
                    WandererTradeDescription.TradeRarity.RARE, 5, 5, 0.5f
            )
    ));
}

World Features Utils Will be expanded in the next updates.

Read the full description on Modrinth →

Highlights

From source data

Game versions

Supports 6 Minecraft versions, the newest being 1.20.6.

Loaders

Runs on Forge.

Footprint

Rated a light load on a server.

What kind of mod it is

From the catalog
Listed on Modrinth as “Mods”

Libraries & compatibility

Foundations and fixes other mods build on. Usually installed because something else needs it.

Runs on your server

From source side support

Modrinth lists Temporal API as required on the server. Check its Modrinth page to see whether players need it too.

Compatibility

Game
Minecraft
Loaders
Forge
Runs on
Serverrequired on the server
Game versions
1.20.6 and 5 earlier

Verified at the source

  • ✓ModrinthOfficial listing, checked 2026-10-01Open ↗
  • ✓AuthorCyberRat2, as published on Modrinth
  • ✓LicenseLicenseRef-All-Rights-ReservedFree

Temporal API, answered

Generated from the mod’s own source data.

Do my players need to install Temporal API?

Modrinth lists Temporal API as required on the server. Check its Modrinth page to see whether players need it too.

Which loaders does it support?

Forge.

Is it free?

Yes. Temporal API is free to download from Modrinth. Its license is LicenseRef-All-Rights-Reserved.

How do I add it to my Nxeon server?

Use “Add to a server” on this page, or open NxLabs from your dashboard. We install it, restart your server and switch it on.

NxLabs

Run Temporal API on a Minecraft server.

Deploy in about a minute from $4.20 a month, then add Temporal API in one click.