Repository navigation
clicksend 1.0.0
clicksend 1.0.0 is the stable release of the 2014 clicksend gem, rewritten for ClickSend's REST v3 API and modern Ruby. It is a focused, idiomatic SMS client; it is not a replacement for ClickSend's official full-API SDK.
There are no changes to the library's behaviour or public API since 1.0.0.rc1.
gem install clicksendHighlights
- Revival of the 2014 gem. It replaces 0.0.3, which used ClickSend's legacy v2 API.
- Modern Ruby and Faraday. Requires Ruby 3.3+ and Faraday 2, which is the only runtime dependency. Tested on Ruby 3.3, 3.4 and 4.0.
- Focused SMS API:
client.sms.deliverandclient.sms.deliver_batch- delivery receipts and replies
client.account.fetch- lazy pagination
client.request/client.paginatefor any other ClickSend endpoint, through the same authentication, timeouts, retries, errors and parsing
- Typed errors.
ConfigurationError,ConnectionError/TimeoutError,APIErrorand its subclasses,MalformedResponseError, andMessageRejected, which is raised when ClickSend refuses a message inside an HTTP 200. - Retry safety. The gem never re-sends a message that may have reached ClickSend. Requests ClickSend did not process (429s, refused connections, DNS failures, connect timeouts) are retried. Read timeouts, resets, TLS errors and 5xx responses are retried only for idempotent requests.
- Security.
- Clients are immutable and thread-safe, and timeouts are on by default.
- The API key is redacted everywhere.
client.requestcannot send credentials to another host.
Breaking changes from 0.0.x
- The Ruby namespace is now
Clicksend(it wasClickSend), so the gem can be loaded alongside ClickSend's officialclicksend_client6.x. - The legacy v2 client API has been removed.
See MIGRATING.md.
Verification
- Accepted send, verified live. The accepted SMS send path (
POST /v3/sms/send) was verified live against ClickSend's free test number, at no charge. The response was HTTP 200 with statusSUCCESS, an upper-case UUID message ID, an integerdate,message_parts: 0andmessage_price: "0.0000". - Receipts, not live-verified. Receipt retrieval and parsing are verified against ClickSend's published examples and the contract specs. A live receipt was not observed: the test number did not generate one during the two-minute observation window.
Details are in docs/clicksend-api-notes.md.
Publishing
Published to RubyGems from this tag by the Release workflow, using RubyGems Trusted Publishing (OIDC) with no stored API key.
Full changelog: CHANGELOG.md