Skip to content

Commit d882f5a

Browse files
authored
Merge pull request #34 from Dwolla/DEV-1804
Dev 1804: Implement Speakeasy Tests
2 parents 6332772 + 1a2f8de commit d882f5a

File tree

126 files changed

+6094
-333
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

126 files changed

+6094
-333
lines changed

.genignore

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,3 @@
1+
# Manually maintained test files - excluded from Speakeasy generation
2+
src/__tests__/**
3+

.github/workflows/sdk_test.yaml

Lines changed: 21 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,21 @@
1+
name: Test
2+
permissions:
3+
checks: write
4+
contents: write
5+
pull-requests: write
6+
statuses: write
7+
id-token: write
8+
"on":
9+
workflow_dispatch:
10+
inputs:
11+
target:
12+
description: Provided SDK target to run tests for, (all) is valid
13+
type: string
14+
jobs:
15+
test:
16+
uses: speakeasy-api/sdk-generation-action/.github/workflows/sdk-test.yaml@v15
17+
with:
18+
target: ${{ github.event.inputs.target || 'dwolla' }}
19+
secrets:
20+
github_access_token: ${{ secrets.GITHUB_TOKEN }}
21+
speakeasy_api_key: ${{ secrets.SPEAKEASY_API_KEY }}

.speakeasy/gen.lock

Lines changed: 83 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -1,20 +1,20 @@
11
lockVersion: 2.0.0
22
id: 53ac026a-ff11-435d-914b-31df5268afb0
33
management:
4-
docChecksum: 42cfc58c3eb68a6a4de4b47956c205b9
4+
docChecksum: 9fd1bbc68b879020d3e55ac2a43fc6b5
55
docVersion: "2.0"
6-
speakeasyVersion: 1.658.2
7-
generationVersion: 2.755.9
8-
releaseVersion: 0.0.1-beta.13
9-
configChecksum: 0fc627c25b27407851e489453baa2bf5
6+
speakeasyVersion: 1.667.0
7+
generationVersion: 2.769.1
8+
releaseVersion: 0.0.1-beta.14
9+
configChecksum: 9dac73ad419b87dc5e478f4041e6ee4b
1010
repoURL: https://github.com/Dwolla/dwolla-typescript.git
1111
installationURL: https://github.com/Dwolla/dwolla-typescript
1212
published: true
1313
features:
1414
typescript:
1515
additionalDependencies: 0.1.0
1616
constsAndDefaults: 0.1.12
17-
core: 3.26.7
17+
core: 3.26.14
1818
defaultEnabledRetries: 0.1.0
1919
devContainers: 2.90.1
2020
enumUnions: 0.1.0
@@ -24,13 +24,15 @@ features:
2424
globalSecurityCallbacks: 0.1.0
2525
globalServerURLs: 2.83.0
2626
groups: 2.81.3
27+
methodSecurity: 2.82.6
2728
nameOverrides: 2.81.2
2829
oauth2ClientCredentials: 1.1.0
2930
responseFormat: 0.2.3
3031
retries: 2.83.0
31-
sdkHooks: 0.3.0
32+
sdkHooks: 0.4.0
3233
serverIDs: 2.81.2
33-
unions: 2.86.0
34+
tests: 0.17.3
35+
unions: 2.86.3
3436
uploadStreams: 0.1.0
3537
generatedFiles:
3638
- .devcontainer/README.md
@@ -517,6 +519,7 @@ generatedFiles:
517519
- docs/models/operations/createaccountexchangeresponsebody.md
518520
- docs/models/operations/createapplicationaccesstokenrequest.md
519521
- docs/models/operations/createapplicationaccesstokenresponse.md
522+
- docs/models/operations/createapplicationaccesstokensecurity.md
520523
- docs/models/operations/createbeneficialownerdocumentdocumenttype.md
521524
- docs/models/operations/createbeneficialownerdocumentfile.md
522525
- docs/models/operations/createbeneficialownerdocumentrequest.md
@@ -700,7 +703,6 @@ generatedFiles:
700703
- docs/models/operations/simulatebanktransferprocessingrequest.md
701704
- docs/models/operations/simulatebanktransferprocessingresponse.md
702705
- docs/models/operations/to.md
703-
- docs/models/operations/tokentype.md
704706
- docs/models/operations/toledgerentry.md
705707
- docs/models/operations/total.md
706708
- docs/models/operations/transaction.md
@@ -1467,8 +1469,9 @@ generatedFiles:
14671469
- src/types/index.ts
14681470
- src/types/operations.ts
14691471
- src/types/rfcdate.ts
1472+
- src/types/smartUnion.ts
14701473
- src/types/streams.ts
1471-
- src/types/union.ts
1474+
- src/types/unrecognized.ts
14721475
- tsconfig.json
14731476
examples:
14741477
createApplicationAccessToken:
@@ -1477,7 +1480,7 @@ examples:
14771480
application/x-www-form-urlencoded: {"grant_type": "client_credentials"}
14781481
responses:
14791482
"200":
1480-
application/json: {"access_token": "gTm0p62yYXFiB1rOdhV0TsNOinC2V2P1CMaAtojkO9JEGbv3i5", "token_type": "bearer", "expires_in": 3599}
1483+
application/json: {"access_token": "gTm0p62yYXFiB1rOdhV0TsNOinC2V2P1CMaAtojkO9JEGbv3i5", "token_type": "Bearer", "expires_in": 3599}
14811484
"401":
14821485
application/json: {"error": "invalid_client"}
14831486
root:
@@ -1551,7 +1554,7 @@ examples:
15511554
speakeasy-default-list-and-search-customers:
15521555
responses:
15531556
"200":
1554-
application/vnd.dwolla.v1.hal+json: {"_links": {"key": {"href": "https://api.dwolla.com", "type": "application/vnd.dwolla.v1.hal+json", "resource-type": "resource-type"}, "key1": {"href": "https://api.dwolla.com", "type": "application/vnd.dwolla.v1.hal+json", "resource-type": "resource-type"}}, "_embedded": {"customers": [{"_links": {"key": {"href": "https://api.dwolla.com", "type": "application/vnd.dwolla.v1.hal+json", "resource-type": "resource-type"}, "key1": {"href": "https://api.dwolla.com", "type": "application/vnd.dwolla.v1.hal+json", "resource-type": "resource-type"}, "key2": {"href": "https://api.dwolla.com", "type": "application/vnd.dwolla.v1.hal+json", "resource-type": "resource-type"}}, "id": "c41125c5-99c4-4303-a9f6-d066d28a61e3", "firstName": "Jane", "lastName": "Doe", "email": "[email protected]", "correlationId": "CID-abe2bb3d-d2ff-433b-95a3-0debd960ed25", "created": "2022-10-07T16:46:13.023Z", "type": "personal", "status": "verified", "address1": "123 Main Street", "address2": "Ste 123", "city": "Des Moines", "state": "IA", "postalCode": "50309"}]}}
1557+
application/vnd.dwolla.v1.hal+json: {"_links": {"key": {"href": "https://api.dwolla.com", "type": "application/vnd.dwolla.v1.hal+json", "resource-type": "resource-type"}, "key1": {"href": "https://api.dwolla.com", "type": "application/vnd.dwolla.v1.hal+json", "resource-type": "resource-type"}}, "_embedded": {"customers": [{"_links": {"key": {"href": "https://api.dwolla.com", "type": "application/vnd.dwolla.v1.hal+json", "resource-type": "resource-type"}, "key1": {"href": "https://api.dwolla.com", "type": "application/vnd.dwolla.v1.hal+json", "resource-type": "resource-type"}, "key2": {"href": "https://api.dwolla.com", "type": "application/vnd.dwolla.v1.hal+json", "resource-type": "resource-type"}}, "id": "c41125c5-99c4-4303-a9f6-d066d28a61e3", "firstName": "Jane", "lastName": "Doe", "email": "[email protected]", "correlationId": "CID-abe2bb3d-d2ff-433b-95a3-0debd960ed25", "created": "2022-10-07T16:46:13.023Z", "type": "personal", "status": "verified", "address1": "123 Main Street", "address2": "Ste 123", "city": "Des Moines", "state": "IA", "postalCode": "50309"}]}, "total": 2}
15551558
"403":
15561559
application/vnd.dwolla.v1.hal+json: {"code": "Forbidden", "message": "The supplied credentials are not authorized for this resource."}
15571560
createCustomer:
@@ -1976,7 +1979,7 @@ examples:
19761979
id: "<id>"
19771980
responses:
19781981
"200":
1979-
application/vnd.dwolla.v1.hal+json: {"transactions": [{"_links": {"key": {"href": "https://api.dwolla.com", "type": "application/vnd.dwolla.v1.hal+json", "resource-type": "resource-type"}, "key1": {"href": "https://api.dwolla.com", "type": "application/vnd.dwolla.v1.hal+json", "resource-type": "resource-type"}}, "id": "416a2857-c887-4cca-bd02-8c3f75c4bb0e", "status": "pending", "amount": {"value": "2.00", "currency": "USD"}, "created": "2016-02-22T20:46:38.777Z"}], "total": "1"}
1982+
application/vnd.dwolla.v1.hal+json: {"transactions": [{"_links": {"key": {"href": "https://api.dwolla.com", "type": "application/vnd.dwolla.v1.hal+json", "resource-type": "resource-type"}, "key1": {"href": "https://api.dwolla.com", "type": "application/vnd.dwolla.v1.hal+json", "resource-type": "resource-type"}}, "id": "416a2857-c887-4cca-bd02-8c3f75c4bb0e", "status": "pending", "amount": {"value": "2.00", "currency": "USD"}, "created": "2016-02-22T20:46:38.777Z"}], "total": 1}
19801983
"404":
19811984
application/vnd.dwolla.v1.hal+json: {"code": "NotFound", "message": "The requested resource was not found."}
19821985
getTransferFailureReason:
@@ -2526,6 +2529,7 @@ examples:
25262529
responses:
25272530
"200":
25282531
application/json: {"token": "4adF858jPeQ9RnojMHdqSD2KwsvmhO7Ti7cI5woOiBGCpH5krY"}
2532+
application/vnd.dwolla.v1.hal+json: {"token": "4adF858jPeQ9RnojMHdqSD2KwsvmhO7Ti7cI5woOiBGCpH5krY"}
25292533
"400":
25302534
application/vnd.dwolla.v1.hal+json: {"code": "BadRequest", "message": "The request body contains bad syntax or is incomplete."}
25312535
"403":
@@ -2632,4 +2636,69 @@ examples:
26322636
"403":
26332637
application/vnd.dwolla.v1.hal+json: {"code": "forbidden", "message": "Not authorized to simulate transfer processing."}
26342638
examplesVersion: 1.0.2
2635-
generatedTests: {}
2639+
generatedTests:
2640+
createApplicationAccessToken: "2025-11-24T10:10:12-06:00"
2641+
getRoot: "2025-11-24T10:10:12-06:00"
2642+
getAccount: "2025-11-24T10:10:12-06:00"
2643+
listFundingSources: "2025-11-24T10:10:12-06:00"
2644+
listAndSearchTransfers: "2025-11-24T10:10:12-06:00"
2645+
listMassPayments: "2025-11-24T10:10:12-06:00"
2646+
listAccountExchanges: "2025-11-24T10:10:12-06:00"
2647+
createAccountExchange: "2025-11-24T10:10:12-06:00"
2648+
listAndSearchCustomers: "2025-11-24T10:10:12-06:00"
2649+
getCustomer: "2025-11-24T10:10:12-06:00"
2650+
update: "2025-11-24T10:10:12-06:00"
2651+
listAvailableExchangeConnections: "2025-11-24T10:10:12-06:00"
2652+
listBeneficialOwnersForCustomer: "2025-11-24T10:10:12-06:00"
2653+
getBeneficialOwnershipStatusForCustomer: "2025-11-24T10:10:12-06:00"
2654+
certifyBeneficialOwnershipForCustomer: "2025-11-24T10:10:12-06:00"
2655+
listCustomerDocuments: "2025-11-24T10:10:12-06:00"
2656+
listCustomerFundingSources: "2025-11-24T10:10:12-06:00"
2657+
listCustomerTransfers: "2025-11-24T10:10:12-06:00"
2658+
listCustomerMassPayments: "2025-11-24T10:10:12-06:00"
2659+
listCustomerLabels: "2025-11-24T10:10:12-06:00"
2660+
listCustomerExchanges: "2025-11-24T10:10:12-06:00"
2661+
listBusinessClassifications: "2025-11-24T10:10:12-06:00"
2662+
retrieveBusinessClassification: "2025-11-24T10:10:12-06:00"
2663+
retrieveBeneficialOwner: "2025-11-24T10:10:12-06:00"
2664+
updateBeneficialOwner: "2025-11-24T10:10:12-06:00"
2665+
deleteBeneficialOwner: "2025-11-24T10:10:12-06:00"
2666+
listBeneficialOwnerDocuments: "2025-11-24T10:10:12-06:00"
2667+
retrieveDocument: "2025-11-24T10:10:12-06:00"
2668+
getKbaQuestions: "2025-11-24T10:10:12-06:00"
2669+
verifyKbaQuestions: "2025-11-24T10:10:12-06:00"
2670+
getFundingSource: "2025-11-24T10:10:12-06:00"
2671+
updateOrRemoveFundingSource: "2025-11-24T10:10:12-06:00"
2672+
getVanRouting: "2025-11-24T10:10:12-06:00"
2673+
getMicroDeposits: "2025-11-24T10:10:12-06:00"
2674+
verifyMicroDeposits: "2025-11-24T10:10:12-06:00"
2675+
getFundingSourceBalance: "2025-11-24T10:10:12-06:00"
2676+
createOnDemandTransferAuthorization: "2025-11-24T10:10:12-06:00"
2677+
getTransfer: "2025-11-24T10:10:12-06:00"
2678+
cancelTransfer: "2025-11-24T10:10:12-06:00"
2679+
listTransferFees: "2025-11-24T10:10:12-06:00"
2680+
getTransferFailureReason: "2025-11-24T10:10:12-06:00"
2681+
getMassPayment: "2025-11-24T10:10:12-06:00"
2682+
updateMassPayment: "2025-11-24T10:10:12-06:00"
2683+
listMassPaymentItems: "2025-11-24T10:10:12-06:00"
2684+
getMassPaymentItem: "2025-11-24T10:10:12-06:00"
2685+
getLabel: "2025-11-24T10:10:12-06:00"
2686+
removeLabel: "2025-11-24T10:10:12-06:00"
2687+
listLabelLedgerEntries: "2025-11-24T10:10:12-06:00"
2688+
getLabelLedgerEntry: "2025-11-24T10:10:12-06:00"
2689+
retrieveLabelReallocation: "2025-11-24T10:10:12-06:00"
2690+
listEvents: "2025-11-24T10:10:12-06:00"
2691+
getEvent: "2025-11-24T10:10:12-06:00"
2692+
listWebhookSubscriptions: "2025-11-24T10:10:12-06:00"
2693+
getWebhookSubscription: "2025-11-24T10:10:12-06:00"
2694+
updateWebhookSubscription: "2025-11-24T10:10:12-06:00"
2695+
delete: "2025-11-24T10:10:12-06:00"
2696+
listWebhooks: "2025-11-24T10:10:12-06:00"
2697+
getWebhook: "2025-11-24T10:10:12-06:00"
2698+
listWebhookRetries: "2025-11-24T10:10:12-06:00"
2699+
simulateBankTransferProcessing: "2025-11-24T10:10:12-06:00"
2700+
listExchangePartners: "2025-11-24T10:10:12-06:00"
2701+
getExchangePartner: "2025-11-24T10:10:12-06:00"
2702+
getExchange: "2025-11-24T10:10:12-06:00"
2703+
retrieveCustomerExchangeSession: "2025-11-24T10:10:12-06:00"
2704+
createClientToken: "2025-11-24T10:10:12-06:00"

.speakeasy/gen.yaml

Lines changed: 10 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -26,10 +26,10 @@ generation:
2626
requestBodyFieldName: ""
2727
tests:
2828
generateTests: true
29-
generateNewTests: false
29+
generateNewTests: true
3030
skipResponseBodyAssertions: false
3131
typescript:
32-
version: 0.0.1-beta.13
32+
version: 0.0.1-beta.14
3333
acceptHeaderEnum: true
3434
additionalDependencies:
3535
dependencies: {}
@@ -42,7 +42,7 @@ typescript:
4242
author: Speakeasy
4343
baseErrorName: DwollaError
4444
clientServerStatusCodesAsErrors: true
45-
constFieldsAlwaysOptional: true
45+
constFieldsAlwaysOptional: false
4646
defaultErrorName: APIError
4747
enableCustomCodeRegions: false
4848
enableMCPServer: false
@@ -52,6 +52,9 @@ typescript:
5252
exportZodModelNamespace: false
5353
flattenGlobalSecurity: true
5454
flatteningOrder: parameters-first
55+
formStringArrayEncodeMode: encoded-string
56+
forwardCompatibleEnumsByDefault: false
57+
forwardCompatibleUnionsByDefault: "false"
5558
generateExamples: true
5659
imports:
5760
option: openapi
@@ -61,14 +64,18 @@ typescript:
6164
operations: models/operations
6265
shared: models
6366
webhooks: models/webhooks
67+
inferUnionDiscriminators: true
6468
inputModelSuffix: input
6569
jsonpath: rfc9535
70+
laxMode: strict
6671
maxMethodParams: 0
6772
methodArguments: require-security-and-request
6873
modelPropertyCasing: camel
6974
moduleFormat: dual
75+
multipartArrayFormat: legacy
7076
outputModelSuffix: output
7177
packageName: dwolla
78+
preApplyUnionDiscriminators: true
7279
responseFormat: flat
7380
sseFlatResponse: false
7481
templateVersion: v2

.speakeasy/testfiles/example.file

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
hello world

0 commit comments

Comments
 (0)