Closed
Description
Description
To allow integration with the external services Web API for Source Management is required. It should provide set of endpoints enabling third-parties with CRUD operations on Sources.
Acceptance Criteria
- Source Management Web API operates with the data structures described in
SourceInterface
- Source Management Provides the following list of operations on Sources:
- Loading of the single Source entity by identifier with the
GET
request. - Loading the list of Sources filtered by search criteria with the
GET
request. - Creation of the new Source from the
SourceInterface
data with thePOST
request. - Update of the existing Source providing identifier and
SourceInterface
data with thePUT
request.
- Loading of the single Source entity by identifier with the
- ACL is defined for endpoints.
Details
Resource | Request method | Permissions | Payload | Response | Implementation | Description |
---|---|---|---|---|---|---|
/V1/inventory/source/:sourceId |
GET | Admin InventoryApi::source |
SourceInterface |
Magento\InventoryApi\Api\SourceRepositoryInterface::get |
Get Single Source by identifier | |
/V1/inventory/source/search |
GET | Admin InventoryApi::source |
SourceInterface[] |
Magento\InventoryApi\Api\SourceRepositoryInterface::getList |
Load Sources filtered by Search Criteria | |
/V1/inventory/source |
POST | Admin InventoryApi::source , InventoryApi::source_edit |
SourceInterface |
Created source_id |
Magento\InventoryApi\Api\SourceRepositoryInterface::save |
Create Source |
/V1/inventory/source/:sourceId |
PUT | Admin InventoryApi::source |
SourceInterface |
SourceInterface |
Magento\InventoryApi\Api\SourceRepositoryInterface::save |
Update Source |
Documentation: Source WebAPI