Download the PHP package palpalani/baylinks-laravel without Composer

On this page you can find all versions of the php package palpalani/baylinks-laravel. 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 baylinks-laravel

# BayLinks Laravel **A modern, type-safe Laravel SDK for the BayLinks URL shortening platform** [![Latest Version on Packagist](https://img.shields.io/packagist/v/palpalani/baylinks-laravel.svg?style=flat-square)](https://packagist.org/packages/palpalani/baylinks-laravel) [![GitHub Tests Action Status](https://img.shields.io/github/actions/workflow/status/palpalani/baylinks-laravel/run-tests.yml?branch=main&label=tests&style=flat-square)](https://github.com/palpalani/baylinks-laravel/actions?query=workflow%3Arun-tests+branch%3Amain) [![PHPStan](https://img.shields.io/github/actions/workflow/status/palpalani/baylinks-laravel/phpstan.yml?branch=main&label=phpstan&style=flat-square)](https://github.com/palpalani/baylinks-laravel/actions?query=workflow%3Aphpstan+branch%3Amain) [![Code Coverage](https://img.shields.io/github/actions/workflow/status/palpalani/baylinks-laravel/coverage.yml?branch=main&label=coverage&style=flat-square)](https://github.com/palpalani/baylinks-laravel/actions?query=workflow%3A"Code+Coverage"+branch%3Amain) [![Security Scan](https://img.shields.io/github/actions/workflow/status/palpalani/baylinks-laravel/security.yml?branch=main&label=security&style=flat-square)](https://github.com/palpalani/baylinks-laravel/actions?query=workflow%3A"Security+Scan"+branch%3Amain) [![Code Style](https://img.shields.io/github/actions/workflow/status/palpalani/baylinks-laravel/fix-php-code-style-issues.yml?branch=main&label=code%20style&style=flat-square)](https://github.com/palpalani/baylinks-laravel/actions?query=workflow%3A"Fix+PHP+code+style+issues"+branch%3Amain) [![Total Downloads](https://img.shields.io/packagist/dt/palpalani/baylinks-laravel.svg?style=flat-square)](https://packagist.org/packages/palpalani/baylinks-laravel) [![PHP Version](https://img.shields.io/packagist/php-v/palpalani/baylinks-laravel?style=flat-square)](https://packagist.org/packages/palpalani/baylinks-laravel) [![Laravel Version](https://img.shields.io/badge/Laravel-10%20%7C%2011%20%7C%2012-FF2D20?style=flat-square&logo=laravel)](https://laravel.com) [![License](https://img.shields.io/packagist/l/palpalani/baylinks-laravel.svg?style=flat-square)](LICENSE.md) [Features](#features) • [Installation](#installation) • [Usage](#usage) • [API Reference](#api-reference) • [Contributing](#contributing)

About

This Laravel package provides an elegant, fluent interface to the BayLinks API - a powerful URL shortening and management platform for modern businesses. Built on top of Saloon PHP, this SDK offers type-safe request/response handling, robust error management, and seamless Laravel integration.

Features

Requirements

Installation

Install the package via Composer:

Configuration

Publish the configuration file:

This creates config/baylinks-laravel.php with the following structure:

Update your .env file:

Usage

Basic Examples

Retrieve Account Information

Create a Single Short URL

Create Multiple Short URLs (Bulk)

Advanced Usage

Update Short URL Status

Retrieve Visit Records

Using Dependency Injection

Error Handling

API Reference

Client Initialization

Available Methods

Account Operations

Method Description Parameters
accountDetails()->get($apiKey) Retrieve account information string $apiKey

URL Operations

Method Description Parameters
createShortURL()->post($apiKey, $data) Create a single short URL string $apiKey, array $data
createBulkURL()->post($apiKey, $data) Create multiple short URLs string $apiKey, array $data
updateShortURLStatus()->post($apiKey, $data) Update URL status string $apiKey, array $data
ShortUrlVisitRecord()->post($apiKey, $data) Get visit analytics string $apiKey, array $data

Request Payload Schemas

Create Short URL

Create Bulk URLs

Testing

Run the full test suite with Pest:

Run tests with coverage:

Run specific test file:

Run tests with filtering:

Code Quality

Run PHPStan static analysis:

Format code with Laravel Pint:

Development

Architecture

This package uses Saloon PHP for HTTP client abstraction:

Adding New Endpoints

  1. Create a new Request class in src/Requests/{Category}/
  2. Create a corresponding Response class in src/Responses/{Category}/
  3. Add a Resource method or create new Resource in src/Resources/
  4. Update the Factory with a new resource method if needed
  5. Write tests in tests/

See CLAUDE.md for detailed development guidelines.

Continuous Integration

This package uses GitHub Actions for automated testing and quality checks:

Workflow Purpose Trigger
Tests Run Pest tests across PHP 8.3-8.4, Laravel 11-12, Ubuntu/Windows Push, PR
PHPStan Static analysis at level 4 Push, PR
Code Coverage Track test coverage with Codecov Push, PR
Security Scan Composer audit, dependency review, SBOM generation Push, PR, Weekly
Code Style Auto-fix with Laravel Pint Push (branches only)
PR Quality Validate composer.json, check for debug statements PR only

All workflows use Composer caching for faster builds and concurrency controls to prevent redundant runs.

Troubleshooting

Common Issues

"Class 'BayLinks' not found"

Make sure you've published the service provider:

Authentication Errors

Verify your API key is correct and active:

SSL Certificate Issues

If you encounter SSL errors in development:

Changelog

Please see CHANGELOG for recent changes and version history.

Contributing

We welcome contributions! Here's how you can help:

Getting Started

  1. Fork the repository
  2. Create a feature branch: git checkout -b feature/my-new-feature
  3. Make your changes and commit: git commit -am 'Add new feature'
  4. Push to the branch: git push origin feature/my-new-feature
  5. Submit a pull request

Development Guidelines

Running Tests

Pull Request Checklist

Security

If you discover any security-related issues, please email [email protected] instead of using the issue tracker. All security vulnerabilities will be promptly addressed.

Credits

License

The MIT License (MIT). Please see License File for more information.


**[⬆ Back to Top](#baylinks-laravel)** Made with ❤️ by [palPalani](https://github.com/palpalani)

All versions of baylinks-laravel with dependencies

PHP Build Version
Package Version
Requires php Version ^8.3
illuminate/contracts Version ^10.0 || ^11.0 || ^12.0
saloonphp/saloon Version ^3.14
spatie/laravel-package-tools Version ^1.92.7
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 palpalani/baylinks-laravel contains the following files

Loading the files please wait ...