acumaticalibrary / noobgrammer
Acumatica with Guzzle implimentation
Requires
- guzzlehttp/guzzle: ^7.8.0
This package is auto-updated.
Last update: 2026-08-02 11:12:36 UTC
README
A lightweight PHP wrapper for calling the Acumatica ERP Web Service Endpoint (contract-based REST API) and OData services — handling login, requests, and logout for you.
Table of Contents
Description
This library provides a simple interface for authenticating with and sending requests to an Acumatica ERP Web Service Endpoint. It manages the login/request/logout lifecycle automatically and also supports reading data from Acumatica Generic Inquiries exposed via OData.
Built for personal/internal use — shared here in case it helps others integrating with Acumatica.
Getting Started
Dependencies
- PHP 7.4+
- Guzzle HTTP Client
Installing
composer require acumaticalibrary/noobgrammer:master-dev
Usage
Calling the Web Service Endpoint
Build your payload, then pass it to acumatica_Api(). The library logs in, performs the request, and logs out for you.
$datafield = [ "CustomerID" => ["value" => "#"], "CustomerName" => ["value" => "#"], "CustomerClass" => ["value" => "INDVS"], "Status" => ["value" => "#"], "StatementCycleID" => ["value" => "#"], "FinancingDimensionCustomer" => ["value" => true], "CashDiscountAccount" => ["value" => "#"], "CashDiscountSub" => ["value" => "#"], "ARAccount" => ["value" => "#"], "ARSub" => ["value" => "#"], "SalesAccount" => ["value" => "#"], "SalesSub" => ["value" => "#"], "MainContact" => [ "CompanyName" => ["value" => "#"], "DisplayName" => ["value" => "#"], "FirstName" => ["value" => "#"], "LastName" => ["value" => "#"], "DateofBirth" => ["value" => "#"], "Phone1" => ["value" => "#"], "Calendar" => ["value" => "#"], "AddressLine2" => ["value" => "#"], "AddressLine1" => ["value" => "#"], "City" => ["value" => "#"], "State" => ["value" => "#"], "Country" => ["value" => "#"], ], ]; $requestData = [ 'acumaticaLoginEndPoint' => '#', 'acumaticaLogoutEndPoint' => '#', 'Login_Acumatica' => [ 'name' => 'yourUsername', 'password' => 'yourPassword', 'tenant' => 'yourTenant', 'branch' => '', 'locale' => '', ], 'Body_Acumatica' => [ 'Action' => 'PUT', 'URL' => 'YourAcumaticaEndPoint', 'data' => $datafield, ], ]; return json_encode($this->acumatica->acumatica_Api($requestData));
Accessing OData
- In Acumatica, go to Generic Inquiry and create a new Generic Inquiry.
- Once created, tick OData and update/save.
- In your PHP application, call the endpoint like this:
$odataServices = [ 'URL' => 'YourAcumaticaEndPoint', 'name' => 'yourUsername', 'password' => 'yourPassword', ]; return $this->acumatica->odataParse($odataServices);
Version History
- 0.1.1
- Initial Release
License
This project is licensed under the Greggy License — see the LICENSE.md file for details.
Acknowledgments
Inspiration, code snippets, etc.