Skip to content
Merged
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
The table of contents is too big for display.
Diff view
Diff view
  •  
  •  
  •  
23 changes: 23 additions & 0 deletions .devcontainer/Dockerfile
Original file line number Diff line number Diff line change
@@ -0,0 +1,23 @@
# syntax=docker/dockerfile:1
FROM debian:bookworm-slim

RUN apt-get update && apt-get install -y --no-install-recommends \
libxkbcommon0 \
ca-certificates \
ca-certificates-java \
make \
curl \
git \
openjdk-17-jdk-headless \
unzip \
libc++1 \
vim \
&& apt-get clean autoclean

# Ensure UTF-8 encoding
ENV LANG=C.UTF-8
ENV LC_ALL=C.UTF-8

WORKDIR /workspace

COPY . /workspace
20 changes: 20 additions & 0 deletions .devcontainer/devcontainer.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,20 @@
// For format details, see https://aka.ms/devcontainer.json. For config options, see the
// README at: https://github.com/devcontainers/templates/tree/main/src/debian
{
"name": "Debian",
"build": {
"dockerfile": "Dockerfile"
}

// Features to add to the dev container. More info: https://containers.dev/features.
// "features": {},

// Use 'forwardPorts' to make a list of ports inside the container available locally.
// "forwardPorts": [],

// Configure tool-specific properties.
// "customizations": {},

// Uncomment to connect as root instead. More info: https://aka.ms/dev-containers-non-root.
// "remoteUser": "root"
}
5 changes: 5 additions & 0 deletions .gitattributes
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
#
# https://help.github.com/articles/dealing-with-line-endings/
#
# These are explicitly windows files and should use crlf
*.bat text eol=crlf
39 changes: 0 additions & 39 deletions .github/workflows/ci.yaml

This file was deleted.

54 changes: 54 additions & 0 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,54 @@
name: CI
on:
push:
branches-ignore:
- 'generated'
- 'codegen/**'
- 'integrated/**'
- 'stl-preview-head/**'
- 'stl-preview-base/**'

jobs:
lint:
timeout-minutes: 10
name: lint
runs-on: ${{ github.repository == 'stainless-sdks/knock-java' && 'depot-ubuntu-24.04' || 'ubuntu-latest' }}

steps:
- uses: actions/checkout@v4

- name: Set up Java
uses: actions/setup-java@v4
with:
distribution: temurin
java-version: |
8
21
cache: gradle

- name: Set up Gradle
uses: gradle/actions/setup-gradle@v4

- name: Run lints
run: ./scripts/lint
test:
timeout-minutes: 10
name: test
runs-on: ${{ github.repository == 'stainless-sdks/knock-java' && 'depot-ubuntu-24.04' || 'ubuntu-latest' }}
steps:
- uses: actions/checkout@v4

- name: Set up Java
uses: actions/setup-java@v4
with:
distribution: temurin
java-version: |
8
21
cache: gradle

- name: Set up Gradle
uses: gradle/gradle-build-action@v2

- name: Run tests
run: ./scripts/test
41 changes: 41 additions & 0 deletions .github/workflows/publish-sonatype.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,41 @@
# This workflow is triggered when a GitHub release is created.
# It can also be run manually to re-publish to Sonatype in case it failed for some reason.
# You can run this workflow by navigating to https://www.github.com/knocklabs/knock-java/actions/workflows/publish-sonatype.yml
name: Publish Sonatype
on:
workflow_dispatch:

release:
types: [published]

jobs:
publish:
name: publish
runs-on: ubuntu-latest

steps:
- uses: actions/checkout@v4

- name: Set up Java
uses: actions/setup-java@v3
with:
distribution: temurin
java-version: |
8
17
cache: gradle

- name: Set up Gradle
uses: gradle/gradle-build-action@v2

- name: Publish to Sonatype
run: |-
export -- GPG_SIGNING_KEY_ID
printenv -- GPG_SIGNING_KEY | gpg --batch --passphrase-fd 3 --import 3<<< "$GPG_SIGNING_PASSWORD"
GPG_SIGNING_KEY_ID="$(gpg --with-colons --list-keys | awk -F : -- '/^pub:/ { getline; print "0x" substr($10, length($10) - 7) }')"
./gradlew publishAndReleaseToMavenCentral --stacktrace -PmavenCentralUsername="$SONATYPE_USERNAME" -PmavenCentralPassword="$SONATYPE_PASSWORD" --no-configuration-cache
env:
SONATYPE_USERNAME: ${{ secrets.KNOCK_SONATYPE_USERNAME || secrets.SONATYPE_USERNAME }}
SONATYPE_PASSWORD: ${{ secrets.KNOCK_SONATYPE_PASSWORD || secrets.SONATYPE_PASSWORD }}
GPG_SIGNING_KEY: ${{ secrets.KNOCK_SONATYPE_GPG_SIGNING_KEY || secrets.GPG_SIGNING_KEY }}
GPG_SIGNING_PASSWORD: ${{ secrets.KNOCK_SONATYPE_GPG_SIGNING_PASSWORD || secrets.GPG_SIGNING_PASSWORD }}
24 changes: 24 additions & 0 deletions .github/workflows/release-doctor.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,24 @@
name: Release Doctor
on:
pull_request:
branches:
- main
workflow_dispatch:

jobs:
release_doctor:
name: release doctor
runs-on: ubuntu-latest
if: github.repository == 'knocklabs/knock-java' && (github.event_name == 'push' || github.event_name == 'workflow_dispatch' || startsWith(github.head_ref, 'release-please') || github.head_ref == 'next')

steps:
- uses: actions/checkout@v4

- name: Check release environment
run: |
bash ./bin/check-release-environment
env:
SONATYPE_USERNAME: ${{ secrets.KNOCK_SONATYPE_USERNAME || secrets.SONATYPE_USERNAME }}
SONATYPE_PASSWORD: ${{ secrets.KNOCK_SONATYPE_PASSWORD || secrets.SONATYPE_PASSWORD }}
GPG_SIGNING_KEY: ${{ secrets.KNOCK_SONATYPE_GPG_SIGNING_KEY || secrets.GPG_SIGNING_KEY }}
GPG_SIGNING_PASSWORD: ${{ secrets.KNOCK_SONATYPE_GPG_SIGNING_PASSWORD || secrets.GPG_SIGNING_PASSWORD }}
36 changes: 0 additions & 36 deletions .github/workflows/release.yml

This file was deleted.

7 changes: 4 additions & 3 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
.prism.log
.gradle
.idea
.kotlin
build
.env
*.pgp
bin/
codegen.log
kls_database.db
3 changes: 3 additions & 0 deletions .release-please-manifest.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
{
".": "1.0.0"
}
4 changes: 4 additions & 0 deletions .stats.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
configured_endpoints: 89
openapi_spec_url: https://storage.googleapis.com/stainless-sdk-openapi-specs/knock%2Fknock-5176d1bb3a88b127808b197c9ae1cf366fd56599fd8c7b7241ac829e72d69a42.yml
openapi_spec_hash: 92953a04021af2d0132fd9eebeb844b9
config_hash: 7460c5bd6d1a7041faa274f677789407
1 change: 0 additions & 1 deletion .tool-versions

This file was deleted.

32 changes: 30 additions & 2 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,3 +1,31 @@
## v0.2.3
# Changelog

* Add support for using the `Idempotency-Key` header on workflow trigger requests.
## 1.0.0 (2025-05-09)

Full Changelog: [v0.2.10...v1.0.0](https://github.com/knocklabs/knock-java/compare/v0.2.10...v1.0.0)

### Features

* **api:** api update ([690bacd](https://github.com/knocklabs/knock-java/commit/690bacd0ef95b8cf2f19f1863625960d40a96fcf))
* **api:** change bearer to apiKey ([d551d83](https://github.com/knocklabs/knock-java/commit/d551d831c55388387d01f8893cf9296feb00ff44))
* **api:** manual updates ([dc062fa](https://github.com/knocklabs/knock-java/commit/dc062fa71aedd3413d97fb898466d5e60121804f))
* **api:** manual updates ([70c325e](https://github.com/knocklabs/knock-java/commit/70c325e24082e382fa28d173fd659536fd82b11e))
* **api:** manual updates ([a63b672](https://github.com/knocklabs/knock-java/commit/a63b6721aa89122ed7aad6198fe41141ef5a6399))
* **client:** allow providing some params positionally ([70694bc](https://github.com/knocklabs/knock-java/commit/70694bc27236ba551d855f16d261dd9d615c8868))
* update java publishing ([9c7dcda](https://github.com/knocklabs/knock-java/commit/9c7dcda6abcbac6c2ed88e5c4c4be9fc02e7539f))


### Bug Fixes

* compilation errors ([df89e10](https://github.com/knocklabs/knock-java/commit/df89e10864b079c4140c1cfd310ab1611204585b))


### Chores

* **internal:** remove flaky `-Xbackend-threads=0` option ([51c85db](https://github.com/knocklabs/knock-java/commit/51c85db2e6726d5c5c466aa0b140722efd3ba788))
* **internal:** update java toolchain ([a656f21](https://github.com/knocklabs/knock-java/commit/a656f210172b3b57736cb969a2d9a71e04827389))
* sync repo ([320706d](https://github.com/knocklabs/knock-java/commit/320706da86be9bcb13493fdea2aeea93932062c1))
* update SDK settings ([a768a6b](https://github.com/knocklabs/knock-java/commit/a768a6b6dd0ab6757bcb7d356f10d99096ccf792))
* update SDK settings ([e4268c8](https://github.com/knocklabs/knock-java/commit/e4268c8f6a2965e1e99b0ee161ed55acb7d0085e))
* update SDK settings ([7b950c7](https://github.com/knocklabs/knock-java/commit/7b950c7f4e1bea758c8e8c383648aa79d73063ae))
* update SDK settings ([64a3291](https://github.com/knocklabs/knock-java/commit/64a32915952e528c1646cbf932e1b8b794e5d1c7))
29 changes: 0 additions & 29 deletions CONTRIBUTING.md

This file was deleted.

Loading