Download the PHP package softan/mailing-php-sdk without Composer

On this page you can find all versions of the php package softan/mailing-php-sdk. It is possible to download/install these versions without Composer. Possible dependencies are resolved automatically.

FAQ

After the download, you have to make one include require_once('vendor/autoload.php');. After that you have to import the classes with use statements.

Example:
If you use only one package a project is not needed. But if you use more then one package, without a project it is not possible to import the classes with use statements.

In general, it is recommended to use always a project to download your libraries. In an application normally there is more than one library needed.
Some PHP packages are not free to download and because of that hosted in private repositories. In this case some credentials are needed to access such packages. Please use the auth.json textarea to insert credentials, if a package is coming from a private repository. You can look here for more information.

  • Some hosting areas are not accessible by a terminal or SSH. Then it is not possible to use Composer.
  • To use Composer is sometimes complicated. Especially for beginners.
  • Composer needs much resources. Sometimes they are not available on a simple webspace.
  • If you are using private repositories you don't need to share your credentials. You can set up everything on our site and then you provide a simple download link to your team member.
  • Simplify your Composer build process. Use our own command line tool to download the vendor folder as binary. This makes your build process faster and you don't need to expose your credentials for private repositories.
Please rate this library. Is it a good library?

Informations about the package mailing-php-sdk

Softan Mailing SDK (PHP)

Latest Stable Version Total Downloads

Descripción

SDK oficial para integrar aplicaciones con Softan Mailing en PHP. Expone un método estático de alto nivel para enviar correos electrónicos mediante plantillas existentes.

Las credenciales de acceso a la API están embebidas en el SDK (sdk_meta.json). No se requiere ninguna configuración manual de API keys.

Nota: La gestión de templates, cuentas SMTP e instancias se realiza a través del módulo Softan Mailing Module v2 o directamente desde el board de administración. Este SDK está diseñado exclusivamente para el envío de correos desde aplicaciones cliente.

Requisitos

Instalación

Listo. No se necesita ningún paso adicional — las credenciales están embebidas.

Alternativa: instalación desde GitHub (VCS)

Quickstart

Uso en código

Enviar correo por plantilla

Campos requeridos:

Campo Tipo Descripción
template_key string Clave del template (tpl_...)
recipient_email string Correo del destinatario
recipient_name string Nombre del destinatario
email_params array Parámetros del template (mapa clave-valor)

Respuesta exitosa:

Entornos

El SDK incluye credenciales para stg y prod. El entorno por defecto es stg.

En stg, todos los correos son redirigidos al destinatario sandbox configurado en el servidor (SMTP sandbox). En prod, los correos se envían al destinatario real.

Cambiar el entorno activo

Opción 1 — CLI (recomendado para configuración persistente):

Crea o actualiza sdk_config.json con el entorno seleccionado. Ese archivo persiste entre requests hasta que se vuelva a ejecutar el script.

Opción 2 — Programática (recomendado para proyectos con entorno fijo en código):

El SDK usa inicialización lazy: si el proyecto pre-configura SDK::$META y SDK::$CONFIG antes de la primera llamada a un servicio, esos valores se usan durante todo el ciclo de vida de la request.

Si no se realiza ninguna inicialización previa, el SDK usa stg como entorno por defecto (definido en sdk_meta.json).

Configuración

Las credenciales de API están embebidas en sdk_meta.json (XOR+base64). No es necesario ni recomendable crear un sdk_config.json con credenciales.

El único uso válido de sdk_config.json es sobrescribir el entorno activo cuando se prefiere configuración en archivo en lugar de código:

sdk_config.json debe ir en .gitignore si se crea. No está incluido en el repositorio del SDK.

TLS

La verificación TLS está habilitada por defecto. Para desarrollo puedes desactivarla por llamada:

Compatibilidad

Desarrollo

CI: el workflow en .github/workflows/ci.yml valida Composer e integra PHPUnit en PHP 8.1/8.2/8.3.

Licencia

MIT (ver composer.json).


All versions of mailing-php-sdk with dependencies

PHP Build Version
Package Version
Requires php Version >=8.1
ext-curl Version *
ext-json Version *
Composer command for our command line client (download client) This client runs in each environment. You don't need a specific PHP version etc. The first 20 API calls are free. Standard composer command

The package softan/mailing-php-sdk contains the following files

Loading the files please wait ...