Skip to content

chore(release): major sdk v2.0.0 update with newest api coverage#49

Merged
yanuaraditia merged 19 commits intomainfrom
update_sdk
Apr 15, 2026
Merged

chore(release): major sdk v2.0.0 update with newest api coverage#49
yanuaraditia merged 19 commits intomainfrom
update_sdk

Conversation

@yanuaraditia
Copy link
Copy Markdown
Collaborator

No description provided.

@yanuaraditia yanuaraditia changed the title patch(major): prepare sdk v2.*.* patch(major): prepare sdk v2.0.0 Apr 14, 2026
@yanuaraditia yanuaraditia changed the title patch(major): prepare sdk v2.0.0 chore(releae): major sdk v2.0.0 update with newest api coverage Apr 14, 2026
@yanuaraditia yanuaraditia added the enhancement New feature or request label Apr 14, 2026
@yanuaraditia yanuaraditia requested a review from Copilot April 14, 2026 08:08
Copy link
Copy Markdown
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

This PR bumps the SDK to v2.0.0 and expands API coverage (instant tracking, couriers, sub-districts), while also updating validation, tests, CI, and release tooling to support the new surface area.

Changes:

  • Add new services/repositories/contracts for couriers, sub-districts, and instant tracking, and expose them via KiriminAja.
  • Update instant pricing/request-pickup payload shapes and introduce enums for service/vehicle/courier codes.
  • Modernize tooling: replace validation library, update PHPUnit config/CI matrix, and add changelog + release automation and an example playground.

Reviewed changes

Copilot reviewed 58 out of 59 changed files in this pull request and generated 11 comments.

Show a summary per file
File Description
tests/Services/ShippingInstant/TrackingInstantServiceTest.php Adds tests for instant tracking service
tests/Services/ShippingInstant/RequestPickupInstantServiceTest.php Updates instant pickup tests to new payload fields
tests/Services/ShippingInstant/PriceInstantServiceTest.php Updates instant price tests to new origin/destination structure
tests/Services/Shipping/ShippingMock.php Refactors shipping test mock helper
tests/Services/Shipping/PriceService/PriceServiceSuccessTest.php Updates courier input to enum-backed values
tests/Services/Shipping/PriceService/PriceServiceFailedTest.php Updates courier input to enum-backed values
tests/Services/Preference/PreferenceMock.php Refactors preference test mock helper
tests/Services/Courier/CourierMock.php Adds courier repository overload mock helper
tests/Services/Courier/CourierListService/CourierListServiceSuccessTest.php Adds courier list success test
tests/Services/Courier/CourierListService/CourierListServiceFailedTest.php Adds courier list failure test
tests/Services/Courier/CourierGroupService/CourierGroupServiceSuccessTest.php Adds courier group success test
tests/Services/Courier/CourierGroupService/CourierGroupServiceFailedTest.php Adds courier group failure test
tests/Services/Courier/CourierDetailService/CourierDetailServiceSuccessTest.php Adds courier detail success test
tests/Services/Courier/CourierDetailService/CourierDetailServiceFailedTest.php Adds courier detail failure/empty tests
tests/Services/Address/SubDistrictService/SubDistrictServiceSuccessTest.php Adds sub-district success test
tests/Services/Address/SubDistrictService/SubDistrictServiceFailedTest.php Adds sub-district failure/empty tests
tests/Services/Address/ProvinceService/ProvinceServiceFailedTest.php Updates province failure mock to include message
tests/Services/Address/AddressMock.php Refactors address test mock helper
src/Utils/Validator.php Switches validation implementation and adds result wrapper
src/Services/ShippingInstant/TrackingInstantService.php Adds instant tracking service
src/Services/ShippingInstant/RequestPickupInstantService.php Updates required field check for renamed vehicle field
src/Services/ShippingInstant/PriceInstantService.php Updates validation to new origin/destination fields
src/Services/KiriminAja.php Exposes new sub-district/courier/instant-tracking methods
src/Services/Courier/CourierListService.php Adds courier list service
src/Services/Courier/CourierGroupService.php Adds courier group service
src/Services/Courier/CourierDetailService.php Adds courier detail service
src/Services/Address/SubDistrictService.php Adds sub-district service
src/Services/Address/DistrictByNameService.php Removes unused validator import
src/Services/Address/CityService.php Adapts to new validator result type
src/Repositories/ShippingRepository.php Uses query-based POST for cancel endpoint
src/Repositories/ShippingInstantRepository.php Updates instant endpoints and adds tracking call
src/Repositories/CourierRepository.php Adds courier API repository
src/Repositories/AddressRepository.php Adds sub-district repository method
src/Models/ShippingPriceInstantData.php Reshapes instant pricing model fields
src/Models/RequestPickupInstantData.php Updates instant pickup model fields/mapping
src/Models/PackageInstantData.php Updates instant package schema and mapping
src/Enums/InstantVehicle.php Adds instant vehicle enum
src/Enums/InstantService.php Adds instant service enum
src/Enums/ExpressService.php Adds express courier enum
src/Contracts/ShippingInstantContract.php Adds instant tracking contract method
src/Contracts/KiriminAjaContract.php Adds new public SDK methods to contract
src/Contracts/CourierContract.php Adds courier repository contract
src/Contracts/AddressContract.php Adds sub-districts contract method
src/Base/Api/ApiOptions.php Removes instant base URL logic; adds query-only request method
src/Base/Api/Api.php Adds postWithQuery() API method
phpunit.xml Updates PHPUnit schema and enables fail-on-warning
example/index.php Adds SDK playground HTTP router
example/composer.lock Locks example dependencies
example/composer.json Adds example project composer config
example/README.md Documents playground usage and routes
example/.gitignore Ignores example vendor and env files
example/.env.example Adds example env template
composer.json Bumps SDK version and updates dependencies (PHP 8.1+, new validator, PHPUnit)
changelog.php Adds git-based changelog generator script
README.md Updates docs for new endpoints and new payload shapes
Makefile Adds release/changelog/test automation
CHANGELOG.md Adds generated changelog
.github/workflows/php.yml Updates CI formatting and PHP matrix (8.1–8.4)
.gitattributes Excludes release tooling/changelog from exports
Comments suppressed due to low confidence (1)

src/Services/ShippingInstant/PriceInstantService.php:35

  • This validation now only checks that origin and destination are set, but does not validate required keys (e.g. lat, long, address). That can lead to requests being sent with incomplete payloads and failures later in the API call. Consider validating the expected keys (and their types/ranges) before calling the repository.

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

Comment thread src/Base/Api/ApiOptions.php
Comment thread src/Services/Courier/CourierListService.php
Comment thread src/Services/Courier/CourierGroupService.php
Comment thread src/Services/Address/SubDistrictService.php Outdated
Comment thread src/Services/Address/SubDistrictService.php
Comment thread src/Services/Address/CityService.php Outdated
Comment thread src/Services/ShippingInstant/TrackingInstantService.php
Comment thread src/Services/Courier/CourierDetailService.php
Comment thread changelog.php Outdated
Comment thread src/Utils/Validator.php Outdated
@yanuaraditia yanuaraditia changed the title chore(releae): major sdk v2.0.0 update with newest api coverage chore(release): major sdk v2.0.0 update with newest api coverage Apr 15, 2026
Copy link
Copy Markdown

@anggi-susanto anggi-susanto left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

APPROVED

@yanuaraditia yanuaraditia merged commit 4305b1e into main Apr 15, 2026
6 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

enhancement New feature or request

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants