Weave Code
Weaver
Helps Laravel developers discover, compare, and choose open-source packages. See popularity, security, maintainers, and scores at a glance to make better decisions.
Feedback
Share your thoughts, report bugs, or suggest improvements.
Subject
Message
Multipart Builder

Multipart Builder Laravel Package

yoshi2889/multipart-builder

Build multipart/form-data request bodies programmatically in PHP. Compose text fields and file parts, control boundaries, and produce streams ready to hand to your HTTP client—useful for file uploads and APIs without hand-crafting MIME payloads.

Deep Wiki
Context7

yoshi2889/multipart-builder is a lightweight PHP library for constructing multipart/form-data request bodies programmatically. It helps assemble text fields and file parts into valid multipart payloads without manually managing boundaries or formatting.

  • Build multipart bodies with custom boundaries
  • Add text fields and file uploads
  • Configure per-part headers
  • Framework-agnostic and easy to integrate
  • Simple, readable API for request generation
Frequently asked questions about Multipart Builder
What is yoshi2889/multipart-builder used for?
It is a lightweight PHP package for programmatically building multipart/form-data request bodies. You can add text fields and file parts, then generate a correctly formatted payload with boundaries. It helps avoid manually concatenating multipart strings when sending HTTP uploads or integrating with APIs.
How do I install yoshi2889/multipart-builder?
Install it with Composer using composer require yoshi2889/multipart-builder. Because it is a PHP package, you can use it in any Composer-based project, including Laravel. The provided context does not list a service provider or Laravel-specific setup, so standard Composer autoloading should be sufficient.
Does yoshi2889/multipart-builder work with Laravel?
It can be used inside a Laravel application because Laravel supports Composer packages. It is not described as Laravel-specific, so there is no documented facade or service provider in the provided context. You would typically instantiate the builder in your own code and use the generated payload with your HTTP client.
How do I add text fields and file parts to a multipart body?
The package is designed for adding text fields and file parts programmatically before generating the request body. The exact method names are not included in the provided context, so refer to the package source or README for the concrete API. The result is a multipart/form-data payload with the required boundaries.
Does it generate multipart boundaries automatically?
The package generates correctly formatted multipart payloads with boundaries. That means you do not need to manually construct boundary strings or separator lines. You add the fields and file parts, then use the package output as the request body.
Can I use yoshi2889/multipart-builder with Guzzle or Laravel's HTTP client?
The package produces a multipart/form-data body, so it can be used wherever your HTTP client accepts a raw request body and content type. For Guzzle or Laravel's HTTP client, you would send the generated payload with the appropriate multipart content type and boundary. Confirm the exact integration details against your client's API and the package README.
What are alternatives to yoshi2889/multipart-builder?
Alternatives include using your HTTP client's built-in multipart options, such as Guzzle's multipart request option, or manually building the body. The package is useful when you want explicit control over field and file parts without manual string handling. The provided context does not name specific competing packages.
Is yoshi2889/multipart-builder suitable for production?
It is described as a lightweight package for building multipart request bodies, which is a production-relevant task for uploads and API integrations. The provided context does not include information about test coverage, release history, or maintenance activity. You should review the repository, issue tracker, and dependency constraints before using it in production.
How do I test code that uses yoshi2889/multipart-builder?
You can test the generated payload by asserting that it contains the expected field names, file parts, and boundary formatting. Because the package is framework-agnostic, standard PHP testing tools such as PHPUnit can be used. The provided context does not specify any built-in testing helpers.
Is yoshi2889/multipart-builder maintained and which PHP versions does it support?
The provided context does not include maintenance status, release dates, or PHP version constraints. The repository is listed as unknown, so you should check Packagist and the source repository for current requirements and activity. Composer will also enforce the package's PHP version constraints during installation.
Weaver

How can I help you explore Laravel packages today?

Conversation history is not saved when not logged in.
Prompt
Add packages to context
No packages found.
skyraptor/chatter
edlugz/sasapay
abbasudo/artisan-route
mirvan/ippanel
ignibyte/aic-framework
glavweb/data-schema-bundle
glavweb/datagrid-bundle
tacticmedia/scim-server
uni-method/frame
neika-ai/sdk
adachsoft/php-code-style
pharaonic/laravel-notification-dependencies
beautinow/translug
dev-brainiac/bot-cloaked
octoberrain/html
octoberrain/extension
octoberrain/exception
octoberrain/contracts
adachsoft/api-version-bundle
cgv/localized-resource