Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
5 changes: 0 additions & 5 deletions .gitattributes
Original file line number Diff line number Diff line change
@@ -1,14 +1,9 @@
/art export-ignore
/docs export-ignore
/tests export-ignore
/scripts export-ignore
/.github export-ignore
/.php_cs export-ignore
.editorconfig export-ignore
.gitattributes export-ignore
.gitignore export-ignore
phpstan.neon.dist export-ignore
phpunit.xml.dist export-ignore
CHANGELOG.md export-ignore
CONTRIBUTING.md export-ignore
README.md export-ignore
3 changes: 0 additions & 3 deletions .github/FUNDING.yml

This file was deleted.

33 changes: 9 additions & 24 deletions .github/workflows/formats.yml
Original file line number Diff line number Diff line change
Expand Up @@ -4,41 +4,26 @@ on: ['push', 'pull_request']

jobs:
ci:
runs-on: ${{ matrix.os }}
runs-on: ubuntu-latest

strategy:
fail-fast: true
matrix:
os: [ubuntu-latest]
php: [8.2]
dependency-version: [prefer-stable]

name: Formats P${{ matrix.php }} - ${{ matrix.os }} - ${{ matrix.dependency-version }}
name: Lint & Static Analysis

steps:

- name: Checkout
uses: actions/checkout@v2

- name: Cache dependencies
uses: actions/cache@v1
with:
path: ~/.composer/cache/files
key: dependencies-php-${{ matrix.php }}-composer-${{ hashFiles('composer.json') }}
uses: actions/checkout@v4

- name: Setup PHP
uses: shivammathur/setup-php@v2
with:
php-version: ${{ matrix.php }}
php-version: '8.2'
extensions: dom, mbstring, zip
tools: prestissimo
coverage: pcov
coverage: none

- name: Install Composer dependencies
run: composer update --${{ matrix.dependency-version }} --no-interaction --prefer-dist
- name: Install dependencies
run: composer install --no-interaction --prefer-dist

- name: Coding Style Checks
- name: Coding Style
run: composer test:lint

- name: Type Checks
- name: Static Analysis
run: composer test:types
25 changes: 8 additions & 17 deletions .github/workflows/tests.yml
Original file line number Diff line number Diff line change
Expand Up @@ -4,26 +4,17 @@ on: ['push', 'pull_request']

jobs:
ci:
runs-on: ${{ matrix.os }}
runs-on: ubuntu-latest
strategy:
fail-fast: true
matrix:
os: [ubuntu-latest]
php: [8.2, 8.1]
dependency-version: [prefer-stable]
php: ['8.2', '8.3', '8.4']

name: Tests P${{ matrix.php }} - ${{ matrix.os }} - ${{ matrix.dependency-version }}
name: PHP ${{ matrix.php }}

steps:

- name: Checkout
uses: actions/checkout@v2

- name: Cache dependencies
uses: actions/cache@v1
with:
path: ~/.composer/cache/files
key: dependencies-php-${{ matrix.php }}-composer-${{ hashFiles('composer.json') }}
uses: actions/checkout@v4

- name: Setup PHP
uses: shivammathur/setup-php@v2
Expand All @@ -32,8 +23,8 @@ jobs:
extensions: dom, mbstring, zip
coverage: none

- name: Install Composer dependencies
run: composer update --${{ matrix.dependency-version }} --no-interaction --prefer-dist
- name: Install dependencies
run: composer install --no-interaction --prefer-dist

- name: Integration Tests
run: php ./vendor/bin/pest
- name: Run tests
run: vendor/bin/pest
40 changes: 38 additions & 2 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,8 +1,44 @@
# Changelog

All notable changes to this project will be documented in this file.

The format is based on [Keep a Changelog](http://keepachangelog.com/)
and this project adheres to [Semantic Versioning](http://semver.org/).

## [Unreleased]
- Adds first version
## [1.0.0] - 2026-03-29

### Changed
- Upgraded to Saloon v4 (patches CVE-2026-33942, CVE-2026-33182, CVE-2026-33183)
- Bumped minimum PHP version to 8.2
- Authentication now uses Bearer token (was Token prefix)
- Reorganized requests into subdirectory structure per resource
- Resources now extend Saloon's BaseResource
- All DTOs use readonly properties with proper type narrowing
- Updated dev dependencies: Pest v3, PHPStan v2, symfony/var-dumper v7
- Updated CI workflows for PHP 8.2/8.3/8.4

### Added
- Models resource: list, get, create, update, delete, createPrediction
- Model versions: getVersion, listVersions, deleteVersion
- Deployments resource: list, get, create, update, delete, createPrediction
- Trainings resource: list, get, create, cancel
- Files resource: list, get, upload, delete
- Collections resource: list, get
- Hardware resource: list
- Webhooks resource: getSecret
- Account resource: get
- Prediction cancel endpoint (was orphaned in previous version)
- Synchronous predictions via `wait` parameter (Prefer: wait header)
- Streaming support via `stream` parameter
- Webhook support directly on create methods
- 17 typed DTOs covering every API response
- `fromArray()` static factory on entity DTOs for nested construction

### Fixed
- Trailing newline in PostPredictionCancel endpoint URL
- PredictionsData reading `model` from wrong JSON level
- Missing null-coalescing on nullable fields in list responses

### Removed
- Custom Resource base class (replaced by Saloon's BaseResource)
- Mutable webhook state on PredictionsResource (replaced by direct parameters)
1 change: 1 addition & 0 deletions LICENSE.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
The MIT License (MIT)

Copyright (c) Marcelo Pereira <diagngo@gmail.com>
Copyright (c) Ben Bjurstrom <bbjurstrom@gmail.com>

Permission is hereby granted, free of charge, to any person obtaining a copy
Expand Down
Loading