
Security News
AGENTS.md Gains Traction as an Open Format for AI Coding Agents
AGENTS.md is a fast-growing open format giving AI coding agents a shared, predictable way to understand project setup, style, and workflows.
@rileybarabash/sendblue-ts
Advanced tools
A Typescript Node.js wrapper for the Sendblue API, a service for seamlessly integrating your apps with iMessage.
"sendblue-ts" is a Typescript-friendly Node.js wrapper for the Sendblue API, providing a seamless interface for sending and receiving messages.
Before using this library, you need to get your API keys from Sendblue by signing up for an account here.
Install the sendblue-ts
package using your favourite package manager:
pnpm add @rileybarabash/sendblue-ts
Initialize a new Sendblue
instance with your API keys. You can do so in separate file and import it as a module, or directly in your code.
import { env } from "process"
import Sendblue from "@rileybarabash/sendblue-ts"
/**
* Initialize a Sendblue instance.
*/
export const sendblue: Sendblue = new Sendblue(env.SENDBLUE_PK ?? "", env.SENDBLUE_SK ?? "")
Sends a message to a single recipient.
const response: SendMessageResponse = await sendblue.sendMessage({
number: "+19998887777",
content: "Hello from Sendblue!",
sendStyle: "invisible",
mediaUrl: "https://source.unsplash.com/random.png",
statusCallback: "https://example.com/callback"
})
Sends a message to a group of recipients.
const response: SendblueAPIResponse = await sendblue.sendGroupMessage({
numbers: ["+19998887777", "+19998887778"],
content: "Hello from Sendblue!",
sendStyle: "invisible",
mediaUrl: "https://source.unsplash.com/random.png",
statusCallback: "https://example.com/callback"
})
Gets the message associated with the provided ID.
const response: SendblueAPIResponse = await sendblue.getMessage({ id: "messageId" })
Modifies a message group. Currently only supports adding recipients.
const response: SendblueAPIResponse = await sendblue.modifyGroup({
groupId: "groupId",
modifyType: "add_recipient",
number: "+19998887777"
})
Checks if a number is registered with iMessage.
const response: SendblueAPIResponse = await sendblue.lookup({ number: "+19998887777" })
Sends a typing indicator to the specified recipient.
const response: SendblueAPIResponse = await sendblue.sendTypingIndicator({ number: "+19998887777" })
Retrieves a list of contacts associated with the Sendblue account.
const response: SendblueAPIResponse = await sendblue.getContacts()
Creates a contact from a recipient's contact details.
const response: SendblueAPIResponse = await sendblue.createContact({
number: "+19998887777",
firstName: "First Name",
lastName: "Last Name",
companyName: "Company Name"
})
Deletes a contact with the specified ID.
const response: SendblueAPIResponse = await sendblue.deleteContact({ id: "contactId" })
Gets all of the messages associated with a contact.
const response: SendblueAPIResponse = await sendblue.getMessages({ contactId: "contactId" })
For more details and options, refer to the Sendblue API Documentation.
Made with <3 in YEG <Edmonton, Alberta>
FAQs
A Typescript Node.js wrapper for the Sendblue API, a service for seamlessly integrating your apps with iMessage.
The npm package @rileybarabash/sendblue-ts receives a total of 24 weekly downloads. As such, @rileybarabash/sendblue-ts popularity was classified as not popular.
We found that @rileybarabash/sendblue-ts demonstrated a not healthy version release cadence and project activity because the last version was released a year ago. It has 1 open source maintainer collaborating on the project.
Did you know?
Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.
Security News
AGENTS.md is a fast-growing open format giving AI coding agents a shared, predictable way to understand project setup, style, and workflows.
Security News
/Research
Malicious npm package impersonates Nodemailer and drains wallets by hijacking crypto transactions across multiple blockchains.
Security News
This episode explores the hard problem of reachability analysis, from static analysis limits to handling dynamic languages and massive dependency trees.