Civilian Requests
The API has been deprecated and is no longer in use.
Civilian Information
Now we are going to request an already existing civilians information, For this you will require an already create civilian character inside your guild, Let make the first request with a JSON Body.
Civilian Information
GET
https://roleplaybot.xyz/api/civilian/info
Returns a civilians information
Headers
Authorization*
API_KEY
API Authorization Key
Guild*
GUILD_ID
Discord Guild ID
Request Body
name*
CIV_NAME
Civilian Characters Name
Deleting, Editing And Creating Civilians
With the API you can form almost anything that you can do with the normal version of RoleplayBot, Leaving it ideal for individual projects and different variations of RoleplayBot. If you have created something with RoleplayBot's API then please get in contact with us, We Would love to reward active developers!
Delete Civilian
DELETE
https://roleplaybot.xyz/api/civilian/delete
Deletes a civilian character
Headers
Authorization*
API_KEY
API Authorization Key
Guild*
GUILD_ID
Discord Guild ID
Request Body
name*
CIV_NAME
Civilian Name (String)
Successfully deleted civilian
Edit Civilian
PATCH
https://roleplaybot.xyz/api/civilian/edit
Edits a civilian character with the specified field and value Valid Fields: - hair color (Value: String) - name (Value: String) - age (Value: Number <100) - dob (Value: String) - height (Value: Number <500) - weight (Value: Number <500) - occupation (Value: String) - address (Value: String)
Headers
Authorization*
API_KEY
API Authorization Key
Guild*
GUILD_ID
Discord Guild ID
Request Body
name*
CIV_NAME
Civilian Name (String)
field*
FIELD
Field to edit (Must be listed in valid fields)
value*
VALUE
Value to set (Must match allocated field)
Accessing a guild that is not authorized apart of your API key
Create Civilian
POST
https://roleplaybot.xyz/api/civilian/create
Creates a civilian character with supplied parameters
Headers
Authorization*
API_KEY
API Authorization Key
Guild*
GUILD_ID
Discord Guild ID
Request Body
userID*
USER_ID
Creating Users ID (String)
userName*
USER_NAME
Creating Users Name (String)
name*
CIV_NAME
Civilian Name (String) (<100 Characters)
age*
CIV_AGE
Civilian Age (Number) (<100)
dob*
CIV_DOB
Civilian Date Of Birth (String)
gender*
CIV_GENDER
Civilian Gender (Takes: Male, Female Or Other)
hair*
CIV_HAIR
Civilian Hair Color (String)
weight*
CIV_WEIGHT
Civilian Weight in KG (Number) (<500)
height*
CIV_HEIGHT
Civilian Height in CM (Number) (<500)
address*
CIV_ADDRESS
Civilian Address (String)
occupation*
CIV_OCCUPATION
Civilian Occupation (String)
Accessing a guild that is not authorized apart of your API key
Listing Civilians
To list and view the current amount of active civilians registered inside your guild using the following endpoint, The civilians array with provide an object per civilian. Run the request to get a better idea of the structure
List Civilians
GET
https://roleplaybot.xyz/api/civilian/list
Provides an array with objects per active civilian characters, also returns a value specifying the current amount of civilians
Headers
Authorization*
API_KEY
API Authorization Key
Guild*
GUILD_ID
Discord Guild ID
Accessing a guild that is not authorized apart of your API key
Moving On
Now that you have the general idea of GET, POST, PATCH and DELETE requests its time to move on and expand your knowledge, We recommend checking out the endpoints section for a list of API Endpoints and methods.
Last updated
Was this helpful?