RPG Game Creator · GPT アクション
Create a RPG game
Create a RPG game using a JSON file.
POST /m2_get_random_sequencem2_get_random_sequenceGet a valid random sequence of events, locations, dungeon templates and map template id that you can fit a story into. The service will also return a description of all event ids and a description of the map template id used.
POST /m2_get_possible_valuesm2_get_possible_valuesOnly use this service if you elect not to use the get_random_sequence service. The service will return all possible dungeon templates, a description of all event ids and a description of all possible map templates. This service can be useful if the player ask for a very specific sequence of events.
POST /m2_get_previous_game_protagonistsm2_get_previous_game_protagonistsIf the user ask for a sequel, this service will return the definitions of all protagonists so you can reuse them in the new game.
POST /m2_creategamem2_creategameCreate a game and return a link to play the game. The slash at the end of the link is important and must be kept.
元の API スキーマ
{
"openapi": "3.1.0",
"info": {
"title": "Create a RPG game",
"description": "Create a RPG game using a JSON file.",
"version": "v1.0.0"
},
"servers": [
{
"url": "https://rpgcreator.ai"
}
],
"paths": {
"/m2_get_random_sequence": {
"post": {
"description": "Get a valid random sequence of events, locations, dungeon templates and map template id that you can fit a story into. The service will also return a description of all event ids and a description of the map template id used.",
"operationId": "m2_get_random_sequence",
"parameters": [
{
"name": "version",
"in": "body",
"description": "enter 6 in this field. It will ensure the events generated are compatible with your current version.",
"required": true,
"schema": {
"type": "string"
}
},
{
"name": "world_style",
"in": "body",
"description": "possible values are Medieval (for a medieval style world) and SciFi (for a futurist world).",
"required": true,
"schema": {
"type": "string"
}
},
{
"name": "is_sequel",
"in": "body",
"description": "If this sequence is for a sequel from a previous game, true, otherwise, false. If it is a sequel, the randomizer will not generate to meet new protagonists since the player will start with four protagonists.",
"required": true,
"schema": {
"type": "boolean"
}
}
]
}
},
"/m2_get_possible_values": {
"post": {
"description": "Only use this service if you elect not to use the get_random_sequence service. The service will return all possible dungeon templates, a description of all event ids and a description of all possible map templates. This service can be useful if the player ask for a very specific sequence of events.",
"operationId": "m2_get_possible_values",
"parameters": [
{
"name": "version",
"in": "body",
"description": "enter 6 in this field. It will ensure the events generated are compatible with your current version.",
"required": true,
"schema": {
"type": "string"
}
},
{
"name": "world_style",
"in": "body",
"description": "possible values are Medieval (for a medieval style world) and SciFi (for a futurist world).",
"required": true,
"schema": {
"type": "string"
}
}
]
}
},
"/m2_get_previous_game_protagonists": {
"post": {
"description": "If the user ask for a sequel, this service will return the definitions of all protagonists so you can reuse them in the new game.",
"operationId": "m2_get_previous_game_protagonists",
"parameters": [
{
"name": "previous_game_url",
"in": "body",
"description": "The url of the game that you want to extract the protagonists from.",
"required": true,
"schema": {
"type": "string"
}
}
]
}
},
"/m2_creategame": {
"post": {
"description": "Create a game and return a link to play the game. The slash at the end of the link is important and must be kept.",
"operationId": "m2_creategame",
"parameters": [
{
"name": "game_name",
"in": "body",
"description": "Name of the game",
"required": true,
"schema": {
"type": "string"
}
},
{
"name": "world_style",
"in": "body",
"description": "possible values are Medieval (for a medieval style world) and SciFi (for a futurist world).",
"required": true,
"schema": {
"type": "string"
}
},
{
"name": "sequel_from",
"in": "body",
"description": "If the player elected to keep his protagonists and items from a previous game, provide the link of the previous game.",
"required": false,
"schema": {
"type": "string"
}
},
{
"name": "cover_image_prompt",
"in": "body",
"description": "A prompt that will be sent to DALL-E for the cover image of the game. Make the prompt fit with the initial prompt of the user. Priorize something related to the user prompt over a generic medieval image, it will give a better customized experience. You do not have to generate the actual image, it is just a prompt that will be used to generate the image by the service.",
"required": true,
"schema": {
"type": "string"
}
},
{
"name": "scenario",
"in": "body",
"description": "Scenario of the game, This will be used by an other IA to generate detailed dialogues in all events. Please make sure that the scenario fits the sequence of events. Include as much details as possible about things such as the revealations in the history so the dialogue generated by the other IA will include these elements. Make sure the scenario fits the sequence of events.",
"required": true,
"schema": {
"type": "string"
}
},
{
"name": "dynamic_enemies",
"in": "body",
"description": "If set to true, enemies within the game will be generated by AI (GPT 3.5 and DALL-E 2), taking into account the game's scenario and dungeon template information to create adversaries that better fit the story and environment. If set to false, the game will utilize default enemies, which are classic medieval RPG adversaries such as goblins and skeletons. Enable this option if the game's scenario deviates from the typical medieval setting or if you seek a more personalized experience.",
"required": true,
"schema": {
"type": "boolean"
}
},
{
"name": "map_template_id",
"in": "body",
"description": "Map template used to generate the game.",
"required": true,
"schema": {
"type": "integer"
}
},
{
"name": "first_castle_name",
"in": "body",
"description": "Name of the first castle. If the world style is SciFi, name of the first Space Station",
"required": true,
"schema": {
"type": "string"
}
},
{
"name": "first_castle_king_name",
"in": "body",
"description": "Name of the King of the first castle. If world style is SciFi, name of the Space Commander",
"required": true,
"schema": {
"type": "string"
}
},
{
"name": "first_village_name",
"in": "body",
"description": "Name of the first village.",
"required": true,
"schema": {
"type": "string"
}
},
{
"name": "second_village_name",
"in": "body",
"description": "Name of the second village.",
"required": true,
"schema": {
"type": "string"
}
},
{
"name": "third_village_name",
"in": "body",
"description": "Name of the third village.",
"required": true,
"schema": {
"type": "string"
}
},
{
"name": "first_dungeon_name",
"in": "body",
"description": "Name of the first dungeon.",
"required": true,
"schema": {
"type": "string"
}
},
{
"name": "first_dungeon_template",
"in": "body",
"description": "Name of the first dungeon.",
"required": true,
"schema": {
"type": "string"
}
},
{
"name": "second_dungeon_name",
"in": "body",
"description": "Name of the second dungeon.",
"required": true,
"schema": {
"type": "string"
}
},
{
"name": "second_dungeon_template",
"in": "body",
"description": "Name of the first dungeon.",
"required": true,
"schema": {
"type": "string"
}
},
{
"name": "third_dungeon_name",
"in": "body",
"description": "Name of the third dungeon.",
"required": true,
"schema": {
"type": "string"
}
},
{
"name": "third_dungeon_template",
"in": "body",
"description": "Name of the first dungeon.",
"required": true,
"schema": {
"type": "string"
}
},
{
"name": "first_dungeon_villain_name",
"in": "body",
"description": "Name of the boss of the first dungeon.",
"required": true,
"schema": {
"type": "string"
}
},
{
"name": "second_dungeon_villain_name",
"in": "body",
"description": "Name of the boss of the second dungeon.",
"required": true,
"schema": {
"type": "string"
}
},
{
"name": "main_villain_name",
"in": "body",
"description": "Name of the main villain of the story and boss of the final dungeon.",
"required": true,
"schema": {
"type": "string"
}
},
{
"name": "first_protagonist",
"in": "body",
"description": "Main protagonist of the game.",
"required": true,
"schema": {
"$ref": "#/components/schemas/Protagonist"
}
},
{
"name": "second_protagonist",
"in": "body",
"description": "Second playable protagonist of the game.",
"required": true,
"schema": {
"$ref": "#/components/schemas/Protagonist"
}
},
{
"name": "third_protagonist",
"in": "body",
"description": "Third playable protagonist of the game.",
"required": true,
"schema": {
"$ref": "#/components/schemas/Protagonist"
}
},
{
"name": "fourth_protagonist",
"in": "body",
"description": "Fourth playable protagonist of the game.",
"required": true,
"schema": {
"$ref": "#/components/schemas/Protagonist"
}
},
{
"name": "flow_of_events_ids",
"in": "body",
"description": "The sequence of events of the game.",
"required": true,
"schema": {
"type": "array",
"items": {
"type": "integer"
}
}
},
{
"name": "flow_of_events_locations",
"in": "body",
"description": "List of locations where the flow of events happen. Must be aligned with flow_of_events_ids, enter the names of the locations.",
"required": true,
"schema": {
"type": "array",
"items": {
"type": "string"
}
}
},
{
"name": "ending_text",
"in": "body",
"description": "The text displayed at the end of the game to conclude the story.",
"required": true,
"schema": {
"type": "string"
}
}
],
"deprecated": false
}
}
},
"components": {
"schemas": {
"Protagonist": {
"type": "object",
"properties": {
"name": {
"type": "string",
"description": "Name of the first protagonist"
},
"gender": {
"type": "string",
"description": "male or female"
},
"class": {
"type": "string",
"description": "For Medieval world_style, possible values are: Swordsman, White Mage, Sorcerer or Martial Artist. For SciFi world_style, possible values are: Gunslinger, White Mage, Sorcerer or Martial Artist"
},
"personality": {
"type": "string",
"description": "Describe the personality of the protagonist to help a subsequent AI to generate detailled dialogues"
}
},
"required": [
"name",
"gender",
"class",
"personality"
]
}
}
}
}