A Python library to send SMS using NHN Cloud API
Project description
NHNCloudSMS
This is a Python library for interacting with the NHN Cloud SMS service.
Current version: 0.1.3
Installation
To use this library, you need to have Python installed. You can install the required dependencies using pip:
pip install requests
Usage
Initialization
First, you need to initialize the NHNCloudSMS class with your NHN Cloud app key, secret key, and sender phone number.
from nhncloud_sms import NHNCloudSMS
sms_service = NHNCloudSMS(
app_key='your_app_key',
secret_key='your_secret_key',
sender_phone_number='your_sender_phone_number'
)
Sending SMS
To send a single SMS, use the send_sms method:
response = sms_service.send_sms('recipient_phone_number', 'Your message here')
print(response)
Sending Bulk SMS
To send bulk SMS, use the send_bulk_sms method:
recipient_numbers = ['recipient1_phone_number', 'recipient2_phone_number']
response = sms_service.send_bulk_sms(recipient_numbers, 'Your bulk message here')
print(response)
Scheduling SMS
To schedule an SMS, use the schedule_sms method:
response = sms_service.schedule_sms('recipient_phone_number', 'Your scheduled message here', 'schedule_time')
print(response)
Getting SMS Status
To get the status of a sent SMS, use the get_sms_status method:
response = sms_service.get_sms_status('request_id')
print(response)
Getting Sent SMS List
To get a list of sent SMS messages within a specific date range, use the get_sent_sms_list method:
response = sms_service.get_sent_sms_list('start_date', 'end_date')
print(response)
Make sure to replace placeholders (like 'your_app_key'
, 'your_secret_key'
, etc.) with actual values before using the library.
Contact
Please contact dev@runners.im
Project details
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
File details
Details for the file nhncloud_sms-0.1.3.tar.gz
.
File metadata
- Download URL: nhncloud_sms-0.1.3.tar.gz
- Upload date:
- Size: 4.6 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/5.1.0 CPython/3.8.18
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | 0c42d1ac73eea70953ecba3d160f3ed319b5151c770334c58a78f684f91d8d95 |
|
MD5 | 5af44d4dfdbcb42e7a5ad72f81acf4ec |
|
BLAKE2b-256 | fe837fc4a896732d688d6ed14ffb7dd3c8b9959e83cc2b11b48e57da9cc32861 |
File details
Details for the file nhncloud_sms-0.1.3-py3-none-any.whl
.
File metadata
- Download URL: nhncloud_sms-0.1.3-py3-none-any.whl
- Upload date:
- Size: 5.9 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/5.1.0 CPython/3.8.18
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | 0cda54f2dcd3ba7d8e34854baf3c44403e63e3a666b4882b4fb156baa70e4a98 |
|
MD5 | c66d24063a1088c1ba2e04d6c77ec6ab |
|
BLAKE2b-256 | 02060bbee8389431e3ed1979cae1bca45d117df3d65aa94ff417643d5eb23996 |