Skip to content

[documentcollector] Code generation: update services and models - #591

Open
AdyenAutomationBot wants to merge 1 commit into
mainfrom
sdk-automation/documentcollector
Open

[documentcollector] Code generation: update services and models#591
AdyenAutomationBot wants to merge 1 commit into
mainfrom
sdk-automation/documentcollector

Conversation

@AdyenAutomationBot

Copy link
Copy Markdown
Collaborator

This PR contains the automated changes for the documentcollector service.

The commit history of this PR reflects the adyen-openapi commits that have been applied.

@AdyenAutomationBot
AdyenAutomationBot requested a review from a team as a code owner August 21, 2026 14:01

@gemini-code-assist gemini-code-assist Bot left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Code Review

This pull request introduces the generated documentcollector package for the Cross-border Invoices API, including API client code, document upload endpoints, and related models. However, critical issues were identified in the generated code: the DocumentContext type is undefined, which will cause compilation failures, and the UploadCrossBorderInvoice function completely ignores its input parameters (such as the file and merchant account), rendering the API call non-functional.


// All parameters accepted by DocumentsApi.UploadCrossBorderInvoice
type DocumentsApiUploadCrossBorderInvoiceInput struct {
context *DocumentContext

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

critical

The type DocumentContext is not defined anywhere in the documentcollector package, nor is it imported. This will cause a compilation error (undefined: DocumentContext). Please verify if the model definition for DocumentContext is missing from the OpenAPI specification or if the generator skipped generating it.

Comment on lines +65 to +82
func (a *DocumentsApi) UploadCrossBorderInvoice(ctx context.Context, r DocumentsApiUploadCrossBorderInvoiceInput) (DocumentUploadResponse, *http.Response, error) {
res := &DocumentUploadResponse{}
path := "/crossBorderInvoices"
queryParams := url.Values{}
headerParams := make(map[string]string)
httpRes, err := common.SendAPIRequest(
ctx,
a.Client,
nil,
res,
http.MethodPost,
a.BasePath()+path,
queryParams,
headerParams,
)

return *res, httpRes, err
}

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

critical

The input parameters r.file, r.merchantAccount, and r.context are completely ignored in the UploadCrossBorderInvoice function. The request is sent with a nil body and empty query/header parameters, which makes the API call non-functional (the file is never uploaded). This is likely a code generation issue where multipart form-data or request body mapping is missing in the generator templates or OpenAPI spec.

@AdyenAutomationBot
AdyenAutomationBot force-pushed the sdk-automation/documentcollector branch 2 times, most recently from dcea7cb to ac261bf Compare August 27, 2026 13:59
@AdyenAutomationBot
AdyenAutomationBot force-pushed the sdk-automation/documentcollector branch 2 times, most recently from fc33661 to e860719 Compare September 7, 2026 12:07
@AdyenAutomationBot
AdyenAutomationBot force-pushed the sdk-automation/documentcollector branch from e860719 to 2a3e76d Compare September 9, 2026 11:42
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant