voipsms/README.md

68 lines
1.3 KiB
Markdown
Raw Normal View History

2024-06-11 03:19:12 +02:00
# voipSMS
2024-06-10 01:22:31 +02:00
2024-06-11 03:17:02 +02:00
Python flask app that uses voip.ms to manage a number of DID numbers for SMS. Can be used to get mostly anonymous texts and sms verification.
## How to use
1. Clone the repo
`git clone http://git.community.i2p/anons-voip/voipsms.git && cd voipsms`
2. Create and activate a python venv
`python3 -m venv venv && source ./venv/bin/activate`
3. Install requirements
`pip install -r requirements.txt`
4. Set your config
`vim config.json`
2024-06-11 03:19:12 +02:00
2024-06-11 03:17:02 +02:00
[Read about how to set up your config here!](./README.md#Config)
5. Start up the server
`./run`
## Config
The config used in this project uses the JSON format and expects a `username` and `password`
2024-06-11 03:20:57 +02:00
Ex:
2024-06-11 03:19:12 +02:00
```
2024-06-11 03:17:02 +02:00
{
"username":"voipms-email",
"password":"voipms-api-password"
}
```
## Endpoints
### /numbers
*Returns a list of numbers in use*
Supports: GET
Returns a list of javascript objects with keys: did (int as string), sms_available (boolean as int), mms_available (boolean as int)
### /sms
*Returns sms/mms messages for a given number*
Supports: GET,POST
Expects: string `did`
Returns a list of javascript objects with keys: message (string), did (int as string), contact (string as int), date (date as string), media (list)
### /enablesms
*[DISABLED] Enables sms feature for a given number*
Supports: GET,POST
Expects: string `did`
Returns a boolean as int