Updated So REST API Will Work With Bot #120
Open
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
First time coding something this i guess complicated since im self taught..this is assuming you have RESTAPIEnabled=True RESTAPIPort=8212
In your palwordsettings.ini
I hardcoded it so admin is the default username so when you do /addserver and it asks for ip port there will also be a box that says username:password only enter you admin password for your server. The reason why the box says username:password is because REST API uses BASE64 to encode your password to access stuff, so i set it up where you enter your password regurlarly and then the script will now the username is admin then take your password and encode it with base64 spit that code out into the script and then decode it to get access to the server then itll send the very basic comman curl -L -X GET 'http://localhost:8212/v1/api/info' \ -H 'Accept: application/json'
-H 'Authorization: xxxxxxx
where your ip is what you entered in the pop up it then accepts the api application from palworld which asks for the authorization password which you entered and its converted...this is all i could figure out, i couldnt get it to work like the other servers with the fancy symbols and green buttons but hopefully the original person who created this will be able to edit what i did and pretty it up.