Skip to content

k01e-01/pi3open

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

8 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

pi3open

a PiShock to OpenShock api translation layer ^w^

the api can be found at https://pi3open.isso.moe/, and the documention can be found at https://pishock.com/

usage

note: the GetShockerInfo endpoint is currently not implemented, this may cause issues with some clients

1. get your OpenShock Api Token and Device Id

on the OpenShock website, find the shocker you'd like to use, and press edit, this should bring up a menu, take note of the ID field

now, open Api Tokens, and generate a new one, take note of the token provded to you and do not share it

2. configure the PiShock client

  • ignore the Username field, it is unused
  • add anything to the Name field, it will be used in the OpenShock shocker logs in the By User field
  • set the Code field to the Device ID you got earlier
  • set the Api Key field to the Api Token you got earlier

note: these value names may be different from what the client actually calls them

if your PiShock client has an Api Endpoint field, set it to https://pi3open.isso.moe/ and skip the next step, you are done :D

3. redirect PiShock api calls to pi3open

note: HERE BE DRAGONS! this step may require some technical knowldege, feel free to contact me on Discord @k01e if you encounter issues

note: my server may be assigned a new ip, in which case you will need to reopen the hosts file and change the ip

note: more technical users may want to use a dns proxy instead of editing /etc/hosts, such as Acrylic (Windows) or dnsmasq (Linux & MacOS)

Windows

  1. fetch the current ip address of pi3open.isso.moe here, as of the time of writing it is 140.238.199.3
  2. download the do.pishock.com.crt file in this repo, take note of the path it downloaded to, likely something such as C:\Users\<USERNAME>\Downloads\do.pishock.com.crt
  3. open a new PowerShell window as Administrator
  4. type notepad C:\Windows\System32\drivers\etc\hosts and hit enter
  5. in the notepad window, append <IP HERE> do.pishock.com to the end of the file, replacing <IP HERE> with the ip you got in step 1
  6. save and close the file
  7. type ipconfig /flushdns and hit enter
  8. type Import-Certificate -FilePath "<PATH TO CERT>" -CertStoreLocation Cert:\LocalMachine\Root, replacing <PATH TO CERT> with the path you got in step 2 (making sure the path is between quotes, "like this"), then hit enter
  9. close and reopen your browser

if everything is working correctly, opening https://do.pishock.com/ in the broswer should bring you back here (it may show a security warning first, this is expected and okay)

note: the new certificate may not be recognised by some programs until you restart your computer

MacOS and Linux

note: this documentation is unfinished, please feel free to contribute

support

if you are encountering issues with pi3open, please feel free to reach out to me on Discord @k01e, i am happy to help :3

About

a pishock to openshock api translation layer

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages