Simple fake SMS system for testing environments.
233
Simple fake SMS system for testing environments. Receives messages via HTTP API and stores them in SQLite.
Table messages:
id: INTEGER PRIMARY KEY AUTOINCREMENTmessage_id: TEXT (unique message identifier)datetime: TEXT (message date and time)recipient: TEXT (recipient)body: TEXT (message body)Send an SMS message to multiple recipients.
Request Body:
{
"recipients": ["555-0001", "555-0002"],
"body": "This is a test message"
}
Response (201 Created):
{
"success": true,
"message_id": "msg_663f1a2b3c4d5e",
"recipients_count": 2
}
Access http://localhost:25400 to see all messages in a responsive table.
docker build -t fake-sms .
docker run --rm -it -p 25400:25400 fake-sms
services:
fake-sms:
build: .
ports:
- "25400:25400"
Start:
docker-compose up
Stop:
docker-compose down
docker login
docker build -t siestacat/fake-sms:latest .
With version tag:
docker build -t siestacat/fake-sms:1.0.0 .
docker push siestacat/fake-sms:latest
Push specific version:
docker push siestacat/fake-sms:1.0.0
docker pull siestacat/fake-sms:latest
docker run --rm -it -p 25400:25400 siestacat/fake-sms:latest
services:
fake-sms:
image: siestacat/fake-sms:latest
ports:
- "25400:25400"
curl -X POST http://localhost:25400/api.php \
-H "Content-Type: application/json" \
-d '{
"recipients": ["555-1234"],
"body": "Hello, this is a test message"
}'
Response:
{
"success": true,
"message_id": "msg_663f1a2b3c4d5e",
"recipients_count": 1
}
curl -X POST http://localhost:25400/api.php \
-H "Content-Type: application/json" \
-d '{
"recipients": ["555-1234", "555-5678", "555-9012"],
"body": "Hello everyone, this is a broadcast message"
}'
Response:
{
"success": true,
"message_id": "msg_663f1a2b3c4d5e",
"recipients_count": 3
}
Note: All recipients will share the same message_id in the database.
curl -X POST http://localhost:25400/ -d "action=clear"
Open your browser at http://localhost:25400
Content type
Image
Digest
sha256:6e4629770…
Size
171.6 MB
Last updated
4 months ago
docker pull siestacat/fake-sms