Skip to main content

Very simple SQS Client

Project description

Very Sipmle SQS Client

Requirements

  • Python 3+

Installing

pip install simple-sqs-client

Usage

SQSClientBuilder

You can use SQSClientBuilder which is more flexible approach and allows you to fill the connection parameters in different moment of code execution if necessary. Just keep the variable holding the builder in the scope

with SQSClientBuilder() \
            .with_region(AWS_SQS_REGION) \
            .with_queue_url(AWS_SQS_QUEUE_REACT_URL) \
            .with_aws_credentials(
        aws_access_key_id=AWS_SQS_ACCESS_KEY_ID,
        aws_secret_access_key=AWS_SQS_SECRET_ACCESS_KEY
    ).build() as sqs_client:
    event = {message: "hello world"}
    sqs_client.send_message(body=json_util.dumps(event))

Direct

You can also create Client using its constructor

  SQSClient(region_name, aws_access_key_id, aws_secret_access_key, queue_url)

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

simple_sqs_client-0.9.6.tar.gz (6.7 kB view hashes)

Uploaded Source

Built Distribution

simple_sqs_client-0.9.6-py3-none-any.whl (7.0 kB view hashes)

Uploaded Python 3

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