getPrs() {
+ return prs;
+ }
+
+ public int getCount() {
+ return count;
+ }
+
+ @Override
+ public boolean equals(Object o) {
+ if (this == o) return true;
+ if (o == null || getClass() != o.getClass()) return false;
+ ListPRsResponse that = (ListPRsResponse) o;
+ return count == that.count && Objects.equals(prs, that.prs);
+ }
+
+ @Override
+ public int hashCode() {
+ return Objects.hash(prs, count);
+ }
+
+ @Override
+ public String toString() {
+ return "ListPRsResponse{" +
+ "prs=" + prs +
+ ", count=" + count +
+ '}';
+ }
+}
diff --git a/src/main/java/com/getaxonflow/sdk/types/codegovernance/PRRecord.java b/src/main/java/com/getaxonflow/sdk/types/codegovernance/PRRecord.java
new file mode 100644
index 0000000..c645a86
--- /dev/null
+++ b/src/main/java/com/getaxonflow/sdk/types/codegovernance/PRRecord.java
@@ -0,0 +1,151 @@
+/*
+ * Copyright 2025 AxonFlow
+ *
+ * Licensed under the Apache License, Version 2.0 (the "License");
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+package com.getaxonflow.sdk.types.codegovernance;
+
+import com.fasterxml.jackson.annotation.JsonIgnoreProperties;
+import com.fasterxml.jackson.annotation.JsonProperty;
+
+import java.time.Instant;
+import java.util.Objects;
+
+/**
+ * A PR record in the system.
+ */
+@JsonIgnoreProperties(ignoreUnknown = true)
+public final class PRRecord {
+
+ @JsonProperty("id")
+ private final String id;
+
+ @JsonProperty("pr_number")
+ private final int prNumber;
+
+ @JsonProperty("pr_url")
+ private final String prUrl;
+
+ @JsonProperty("title")
+ private final String title;
+
+ @JsonProperty("state")
+ private final String state;
+
+ @JsonProperty("owner")
+ private final String owner;
+
+ @JsonProperty("repo")
+ private final String repo;
+
+ @JsonProperty("head_branch")
+ private final String headBranch;
+
+ @JsonProperty("base_branch")
+ private final String baseBranch;
+
+ @JsonProperty("files_count")
+ private final int filesCount;
+
+ @JsonProperty("secrets_detected")
+ private final int secretsDetected;
+
+ @JsonProperty("unsafe_patterns")
+ private final int unsafePatterns;
+
+ @JsonProperty("created_at")
+ private final Instant createdAt;
+
+ @JsonProperty("created_by")
+ private final String createdBy;
+
+ @JsonProperty("provider_type")
+ private final String providerType;
+
+ public PRRecord(
+ @JsonProperty("id") String id,
+ @JsonProperty("pr_number") int prNumber,
+ @JsonProperty("pr_url") String prUrl,
+ @JsonProperty("title") String title,
+ @JsonProperty("state") String state,
+ @JsonProperty("owner") String owner,
+ @JsonProperty("repo") String repo,
+ @JsonProperty("head_branch") String headBranch,
+ @JsonProperty("base_branch") String baseBranch,
+ @JsonProperty("files_count") int filesCount,
+ @JsonProperty("secrets_detected") int secretsDetected,
+ @JsonProperty("unsafe_patterns") int unsafePatterns,
+ @JsonProperty("created_at") Instant createdAt,
+ @JsonProperty("created_by") String createdBy,
+ @JsonProperty("provider_type") String providerType) {
+ this.id = id;
+ this.prNumber = prNumber;
+ this.prUrl = prUrl;
+ this.title = title;
+ this.state = state;
+ this.owner = owner;
+ this.repo = repo;
+ this.headBranch = headBranch;
+ this.baseBranch = baseBranch;
+ this.filesCount = filesCount;
+ this.secretsDetected = secretsDetected;
+ this.unsafePatterns = unsafePatterns;
+ this.createdAt = createdAt;
+ this.createdBy = createdBy;
+ this.providerType = providerType;
+ }
+
+ public String getId() { return id; }
+ public int getPrNumber() { return prNumber; }
+ public String getPrUrl() { return prUrl; }
+ public String getTitle() { return title; }
+ public String getState() { return state; }
+ public String getOwner() { return owner; }
+ public String getRepo() { return repo; }
+ public String getHeadBranch() { return headBranch; }
+ public String getBaseBranch() { return baseBranch; }
+ public int getFilesCount() { return filesCount; }
+ public int getSecretsDetected() { return secretsDetected; }
+ public int getUnsafePatterns() { return unsafePatterns; }
+ public Instant getCreatedAt() { return createdAt; }
+ public String getCreatedBy() { return createdBy; }
+ public String getProviderType() { return providerType; }
+
+ @Override
+ public boolean equals(Object o) {
+ if (this == o) return true;
+ if (o == null || getClass() != o.getClass()) return false;
+ PRRecord prRecord = (PRRecord) o;
+ return prNumber == prRecord.prNumber &&
+ Objects.equals(id, prRecord.id) &&
+ Objects.equals(owner, prRecord.owner) &&
+ Objects.equals(repo, prRecord.repo);
+ }
+
+ @Override
+ public int hashCode() {
+ return Objects.hash(id, prNumber, owner, repo);
+ }
+
+ @Override
+ public String toString() {
+ return "PRRecord{" +
+ "id='" + id + '\'' +
+ ", prNumber=" + prNumber +
+ ", title='" + title + '\'' +
+ ", state='" + state + '\'' +
+ ", owner='" + owner + '\'' +
+ ", repo='" + repo + '\'' +
+ '}';
+ }
+}
diff --git a/src/main/java/com/getaxonflow/sdk/types/codegovernance/ValidateGitProviderRequest.java b/src/main/java/com/getaxonflow/sdk/types/codegovernance/ValidateGitProviderRequest.java
new file mode 100644
index 0000000..85903dc
--- /dev/null
+++ b/src/main/java/com/getaxonflow/sdk/types/codegovernance/ValidateGitProviderRequest.java
@@ -0,0 +1,158 @@
+/*
+ * Copyright 2025 AxonFlow
+ *
+ * Licensed under the Apache License, Version 2.0 (the "License");
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+package com.getaxonflow.sdk.types.codegovernance;
+
+import com.fasterxml.jackson.annotation.JsonIgnoreProperties;
+import com.fasterxml.jackson.annotation.JsonProperty;
+
+import java.util.Objects;
+
+/**
+ * Request to validate Git provider credentials.
+ */
+@JsonIgnoreProperties(ignoreUnknown = true)
+public final class ValidateGitProviderRequest {
+
+ @JsonProperty("type")
+ private final GitProviderType type;
+
+ @JsonProperty("token")
+ private final String token;
+
+ @JsonProperty("base_url")
+ private final String baseUrl;
+
+ @JsonProperty("app_id")
+ private final Integer appId;
+
+ @JsonProperty("installation_id")
+ private final Integer installationId;
+
+ @JsonProperty("private_key")
+ private final String privateKey;
+
+ public ValidateGitProviderRequest(
+ @JsonProperty("type") GitProviderType type,
+ @JsonProperty("token") String token,
+ @JsonProperty("base_url") String baseUrl,
+ @JsonProperty("app_id") Integer appId,
+ @JsonProperty("installation_id") Integer installationId,
+ @JsonProperty("private_key") String privateKey) {
+ this.type = Objects.requireNonNull(type, "type is required");
+ this.token = token;
+ this.baseUrl = baseUrl;
+ this.appId = appId;
+ this.installationId = installationId;
+ this.privateKey = privateKey;
+ }
+
+ public GitProviderType getType() {
+ return type;
+ }
+
+ public String getToken() {
+ return token;
+ }
+
+ public String getBaseUrl() {
+ return baseUrl;
+ }
+
+ public Integer getAppId() {
+ return appId;
+ }
+
+ public Integer getInstallationId() {
+ return installationId;
+ }
+
+ public String getPrivateKey() {
+ return privateKey;
+ }
+
+ public static Builder builder() {
+ return new Builder();
+ }
+
+ public static class Builder {
+ private GitProviderType type;
+ private String token;
+ private String baseUrl;
+ private Integer appId;
+ private Integer installationId;
+ private String privateKey;
+
+ public Builder type(GitProviderType type) {
+ this.type = type;
+ return this;
+ }
+
+ public Builder token(String token) {
+ this.token = token;
+ return this;
+ }
+
+ public Builder baseUrl(String baseUrl) {
+ this.baseUrl = baseUrl;
+ return this;
+ }
+
+ public Builder appId(Integer appId) {
+ this.appId = appId;
+ return this;
+ }
+
+ public Builder installationId(Integer installationId) {
+ this.installationId = installationId;
+ return this;
+ }
+
+ public Builder privateKey(String privateKey) {
+ this.privateKey = privateKey;
+ return this;
+ }
+
+ public ValidateGitProviderRequest build() {
+ return new ValidateGitProviderRequest(type, token, baseUrl, appId, installationId, privateKey);
+ }
+ }
+
+ @Override
+ public boolean equals(Object o) {
+ if (this == o) return true;
+ if (o == null || getClass() != o.getClass()) return false;
+ ValidateGitProviderRequest that = (ValidateGitProviderRequest) o;
+ return type == that.type &&
+ Objects.equals(token, that.token) &&
+ Objects.equals(baseUrl, that.baseUrl) &&
+ Objects.equals(appId, that.appId) &&
+ Objects.equals(installationId, that.installationId) &&
+ Objects.equals(privateKey, that.privateKey);
+ }
+
+ @Override
+ public int hashCode() {
+ return Objects.hash(type, token, baseUrl, appId, installationId, privateKey);
+ }
+
+ @Override
+ public String toString() {
+ return "ValidateGitProviderRequest{" +
+ "type=" + type +
+ ", baseUrl='" + baseUrl + '\'' +
+ '}';
+ }
+}
diff --git a/src/main/java/com/getaxonflow/sdk/types/codegovernance/ValidateGitProviderResponse.java b/src/main/java/com/getaxonflow/sdk/types/codegovernance/ValidateGitProviderResponse.java
new file mode 100644
index 0000000..35be9f9
--- /dev/null
+++ b/src/main/java/com/getaxonflow/sdk/types/codegovernance/ValidateGitProviderResponse.java
@@ -0,0 +1,70 @@
+/*
+ * Copyright 2025 AxonFlow
+ *
+ * Licensed under the Apache License, Version 2.0 (the "License");
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+package com.getaxonflow.sdk.types.codegovernance;
+
+import com.fasterxml.jackson.annotation.JsonIgnoreProperties;
+import com.fasterxml.jackson.annotation.JsonProperty;
+
+import java.util.Objects;
+
+/**
+ * Response from Git provider validation.
+ */
+@JsonIgnoreProperties(ignoreUnknown = true)
+public final class ValidateGitProviderResponse {
+
+ @JsonProperty("valid")
+ private final boolean valid;
+
+ @JsonProperty("message")
+ private final String message;
+
+ public ValidateGitProviderResponse(
+ @JsonProperty("valid") boolean valid,
+ @JsonProperty("message") String message) {
+ this.valid = valid;
+ this.message = message != null ? message : "";
+ }
+
+ public boolean isValid() {
+ return valid;
+ }
+
+ public String getMessage() {
+ return message;
+ }
+
+ @Override
+ public boolean equals(Object o) {
+ if (this == o) return true;
+ if (o == null || getClass() != o.getClass()) return false;
+ ValidateGitProviderResponse that = (ValidateGitProviderResponse) o;
+ return valid == that.valid && Objects.equals(message, that.message);
+ }
+
+ @Override
+ public int hashCode() {
+ return Objects.hash(valid, message);
+ }
+
+ @Override
+ public String toString() {
+ return "ValidateGitProviderResponse{" +
+ "valid=" + valid +
+ ", message='" + message + '\'' +
+ '}';
+ }
+}
diff --git a/src/main/java/com/getaxonflow/sdk/types/codegovernance/package-info.java b/src/main/java/com/getaxonflow/sdk/types/codegovernance/package-info.java
new file mode 100644
index 0000000..e176d5f
--- /dev/null
+++ b/src/main/java/com/getaxonflow/sdk/types/codegovernance/package-info.java
@@ -0,0 +1,31 @@
+/*
+ * Copyright 2025 AxonFlow
+ *
+ * Licensed under the Apache License, Version 2.0 (the "License");
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+
+/**
+ * Code Governance types for enterprise Git provider integration.
+ *
+ * This package provides types for:
+ *
+ * - Git provider configuration (GitHub, GitLab, Bitbucket)
+ * - Pull request creation from LLM-generated code
+ * - PR tracking and status synchronization
+ *
+ *
+ * @see com.getaxonflow.sdk.AxonFlow#validateGitProvider
+ * @see com.getaxonflow.sdk.AxonFlow#configureGitProvider
+ * @see com.getaxonflow.sdk.AxonFlow#createPR
+ */
+package com.getaxonflow.sdk.types.codegovernance;