Skip to main content

This is the API SMS Gateway Sayqal.uz

Project description

smsuz

A Python library for sending SMS via the Sayqal.uz SMS gateway. This library allows you to send SMS messages from your Django application easily.

Installation

Install the package via pip:

pip install smsuz

Setup

  1. Add the sms application to your Django project's installed apps. Open your settings.py file and update as follows:

    INSTALLED_APPS = [
        ...
        'sms',
    ]
    
  2. Add the SAYQAL_USERNAME and SAYQAL_SECRETKEY constants to your project settings, which you can obtain after registering on Sayqal.uz:

    # settings.py
    
    SAYQAL_USERNAME = 'your_username_here'
    SAYQAL_SECRETKEY = 'your_secretkey_here'
    
  3. Run the database migrations to apply any necessary changes:

    python manage.py migrate
    

Usage

Import the sendSms function and use it to send SMS messages:

from sms.utils import sendSms

# Example of sending an SMS
sendSms('+998971234567', 'Your SMS message text')

Example

from sms.utils import sendSms

# Send an SMS to the specified phone number
phone_number = '+998971234567'
message = 'Your confirmation code: 123456'
sendSms(phone_number, message)

License

This project is licensed under the MIT License. See the LICENSE file for details.


by AbexLab

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

smsuz-0.0.1.tar.gz (6.7 kB view details)

Uploaded Source

Built Distribution

smsuz-0.0.1-py3-none-any.whl (8.2 kB view details)

Uploaded Python 3

File details

Details for the file smsuz-0.0.1.tar.gz.

File metadata

  • Download URL: smsuz-0.0.1.tar.gz
  • Upload date:
  • Size: 6.7 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/5.1.1 CPython/3.11.9

File hashes

Hashes for smsuz-0.0.1.tar.gz
Algorithm Hash digest
SHA256 cfe62c085e71dda0a6b56d2cf90bec7bc679cc3de5f4bf7f85619c055890c934
MD5 5f2c2a8ac896b8854acdd82f08256a91
BLAKE2b-256 2b211f982f33578f77263c93d09065eeccf8c7ad8f7501bdd0413957af1efa9b

See more details on using hashes here.

File details

Details for the file smsuz-0.0.1-py3-none-any.whl.

File metadata

  • Download URL: smsuz-0.0.1-py3-none-any.whl
  • Upload date:
  • Size: 8.2 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/5.1.1 CPython/3.11.9

File hashes

Hashes for smsuz-0.0.1-py3-none-any.whl
Algorithm Hash digest
SHA256 916c0ae39fbaa972deda80ca0496a28e78cd96a59229f096640d621cc7fc821d
MD5 f8abae697079a0e3b834dda8b06373e5
BLAKE2b-256 fb37dc5eb42141d808ec42256236be6a8fef2b0883bb1231f3104e263610587e

See more details on using hashes here.

Supported by

AWS AWS Cloud computing and Security Sponsor Datadog Datadog Monitoring Fastly Fastly CDN Google Google Download Analytics Microsoft Microsoft PSF Sponsor Pingdom Pingdom Monitoring Sentry Sentry Error logging StatusPage StatusPage Status page