diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index a843e036..c2b98114 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -30,6 +30,30 @@ jobs: - name: Run lints run: ./scripts/lint + upload: + if: github.repository == 'stainless-sdks/finch-python' + timeout-minutes: 10 + name: upload + permissions: + contents: read + id-token: write + runs-on: depot-ubuntu-24.04 + steps: + - uses: actions/checkout@v4 + + - name: Get GitHub OIDC Token + id: github-oidc + uses: actions/github-script@v6 + with: + script: core.setOutput('github_token', await core.getIDToken()); + + - name: Upload tarball + env: + URL: https://pkg.stainless.com/s + AUTH: ${{ steps.github-oidc.outputs.github_token }} + SHA: ${{ github.sha }} + run: ./scripts/utils/upload-artifact.sh + test: timeout-minutes: 10 name: test diff --git a/.release-please-manifest.json b/.release-please-manifest.json index b33e9fd7..4eb89879 100644 --- a/.release-please-manifest.json +++ b/.release-please-manifest.json @@ -1,3 +1,3 @@ { - ".": "1.26.1" + ".": "1.27.0" } \ No newline at end of file diff --git a/.stats.yml b/.stats.yml index ac3940f3..c72261be 100644 --- a/.stats.yml +++ b/.stats.yml @@ -1,4 +1,4 @@ configured_endpoints: 46 -openapi_spec_url: https://storage.googleapis.com/stainless-sdk-openapi-specs/finch%2Ffinch-f09e5f2c555d7ee764478b7bc73e92cd21f403d6ec189be14574c8367bc131ce.yml -openapi_spec_hash: bd0a8e001f14132c105992d40149909a +openapi_spec_url: https://storage.googleapis.com/stainless-sdk-openapi-specs/finch%2Ffinch-5b00a0bc705b1d5bfcb5ea79c7af544766d51ec12ccc4721825664ab397789d8.yml +openapi_spec_hash: 34891659cff31395ba7683a8153b1db5 config_hash: 53778a0b839c4f6ad34fbba051f5e8a6 diff --git a/CHANGELOG.md b/CHANGELOG.md index 3bb44d97..d96ea116 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,5 +1,21 @@ # Changelog +## 1.27.0 (2025-05-16) + +Full Changelog: [v1.26.1...v1.27.0](https://github.com/Finch-API/finch-api-python/compare/v1.26.1...v1.27.0) + +### Features + +* **api:** api update ([abc60a2](https://github.com/Finch-API/finch-api-python/commit/abc60a28fc9fe40464299491ae8209259f8bca78)) +* **api:** api update ([fd20b60](https://github.com/Finch-API/finch-api-python/commit/fd20b60e775673b78edeb40771d8af7f7a55bb08)) +* **api:** api update ([0af1c84](https://github.com/Finch-API/finch-api-python/commit/0af1c8443ffd922047b0f4f892f712668c9f54c9)) + + +### Chores + +* **ci:** fix installation instructions ([ac6a9d8](https://github.com/Finch-API/finch-api-python/commit/ac6a9d8edf95f3343dd38f09693fc7ff22cebd91)) +* **ci:** upload sdks to package manager ([c867997](https://github.com/Finch-API/finch-api-python/commit/c86799760455e97fca934c83e2eef0986d7f8e89)) + ## 1.26.1 (2025-05-09) Full Changelog: [v1.26.0...v1.26.1](https://github.com/Finch-API/finch-api-python/compare/v1.26.0...v1.26.1) diff --git a/pyproject.toml b/pyproject.toml index f9ddadbb..d919801a 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -1,6 +1,6 @@ [project] name = "finch-api" -version = "1.26.1" +version = "1.27.0" description = "The official Python library for the Finch API" dynamic = ["readme"] license = "Apache-2.0" diff --git a/scripts/utils/upload-artifact.sh b/scripts/utils/upload-artifact.sh new file mode 100755 index 00000000..d89a9ed0 --- /dev/null +++ b/scripts/utils/upload-artifact.sh @@ -0,0 +1,25 @@ +#!/usr/bin/env bash +set -exuo pipefail + +RESPONSE=$(curl -X POST "$URL" \ + -H "Authorization: Bearer $AUTH" \ + -H "Content-Type: application/json") + +SIGNED_URL=$(echo "$RESPONSE" | jq -r '.url') + +if [[ "$SIGNED_URL" == "null" ]]; then + echo -e "\033[31mFailed to get signed URL.\033[0m" + exit 1 +fi + +UPLOAD_RESPONSE=$(tar -cz . | curl -v -X PUT \ + -H "Content-Type: application/gzip" \ + --data-binary @- "$SIGNED_URL" 2>&1) + +if echo "$UPLOAD_RESPONSE" | grep -q "HTTP/[0-9.]* 200"; then + echo -e "\033[32mUploaded build to Stainless storage.\033[0m" + echo -e "\033[32mInstallation: pip install 'https://pkg.stainless.com/s/finch-python/$SHA'\033[0m" +else + echo -e "\033[31mFailed to upload artifact.\033[0m" + exit 1 +fi diff --git a/src/finch/_version.py b/src/finch/_version.py index 3b5c8103..5337dd5b 100644 --- a/src/finch/_version.py +++ b/src/finch/_version.py @@ -1,4 +1,4 @@ # File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details. __title__ = "finch" -__version__ = "1.26.1" # x-release-please-version +__version__ = "1.27.0" # x-release-please-version diff --git a/src/finch/types/hris/pay_statement.py b/src/finch/types/hris/pay_statement.py index 24f97b56..7c6f63b6 100644 --- a/src/finch/types/hris/pay_statement.py +++ b/src/finch/types/hris/pay_statement.py @@ -185,7 +185,7 @@ class PayStatement(BaseModel): net_pay: Optional[Money] = None - payment_method: Optional[Literal["check", "direct_deposit"]] = None + payment_method: Optional[Literal["check", "direct_deposit", "other"]] = None """The payment method.""" taxes: Optional[List[Optional[Tax]]] = None diff --git a/src/finch/types/sandbox/payment_create_params.py b/src/finch/types/sandbox/payment_create_params.py index f8744ec1..d35089b0 100644 --- a/src/finch/types/sandbox/payment_create_params.py +++ b/src/finch/types/sandbox/payment_create_params.py @@ -195,7 +195,7 @@ class PayStatement(TypedDict, total=False): net_pay: Optional[MoneyParam] - payment_method: Optional[Literal["check", "direct_deposit"]] + payment_method: Optional[Literal["check", "direct_deposit", "other"]] """The payment method.""" taxes: Optional[Iterable[Optional[PayStatementTax]]]