Skip to content

Commit

Permalink
fix type conflicts (#18)
Browse files Browse the repository at this point in the history
* fix type conflicts

Signed-off-by: Ilias Elbarnoussi <[email protected]>

* fix styling

Signed-off-by: Ilias Elbarnoussi <[email protected]>

---------

Signed-off-by: Ilias Elbarnoussi <[email protected]>
Co-authored-by: Ilias Elbarnoussi <[email protected]>
  • Loading branch information
IliasElbarnoussi and IliasElbarnoussi committed Jun 24, 2024
1 parent 41397d2 commit 642bb76
Show file tree
Hide file tree
Showing 8 changed files with 27 additions and 27 deletions.
1 change: 1 addition & 0 deletions index.ts
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
export * from './src/client'
12 changes: 12 additions & 0 deletions openapi-ts.config.ts
Original file line number Diff line number Diff line change
Expand Up @@ -16,6 +16,18 @@ const config: UserConfig = {
output: 'generated',
services: {
asClass: true,
methodNameBuilder(service, operationId) {
const lowerService = service.toLowerCase()
const lowerOperationId = operationId.toLowerCase()

let methodName = operationId
if (lowerOperationId.startsWith(lowerService)) {
methodName = operationId.slice(service.length)
}

return methodName.charAt(0).toLowerCase() + methodName.slice(1)
},
operationId: true,
},
}

Expand Down
4 changes: 3 additions & 1 deletion package.json
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,8 @@
"name": "@paradym/sdk",
"version": "0.0.0",
"type": "module",
"main": "build/index.js",
"types": "build/index.d.ts",
"license": "Apache-2.0",
"private": false,
"publishConfig": {
Expand All @@ -21,7 +23,7 @@
},
"devDependencies": {
"@biomejs/biome": "1.7.3",
"@hey-api/openapi-ts": "^0.46.3",
"@hey-api/openapi-ts": "^0.47.0",
"@types/node": "^20.12.6",
"dotenv": "^16.4.5",
"release-it": "^17.3.0",
Expand Down
30 changes: 8 additions & 22 deletions pnpm-lock.yaml

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

1 change: 0 additions & 1 deletion src/index.ts

This file was deleted.

2 changes: 1 addition & 1 deletion test/credentialTemplate.test.ts
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@ describe('Credential Template', () => {

it('should return a SdJwtVc credential template', async () => {
const client = new Paradym({ apiKey: process.env.X_ACCESS_TOKEN as string })
const sdJwtCredentialTemplate = await client.templates.credentials.sdJwtVc.getSdJwtVcTemplate({
const sdJwtCredentialTemplate = await client.templates.credentials.sdJwtVc.getCredentialTemplate({
projectId: 'clwt6e610000101s69ubga6lk',
credentialTemplateId: 'clwyt70o50021yylmethefm27',
})
Expand Down
2 changes: 1 addition & 1 deletion test/issuanceSession.test.ts
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ dotenv.config()
describe('Issuance Session', () => {
it('should return all issuance sessions', async () => {
const client = new Paradym({ apiKey: process.env.X_ACCESS_TOKEN as string })
const issuanceSessions = await client.openId4Vc.issuance.getAllOpenId4VcIssuanceSessions({
const issuanceSessions = await client.openId4Vc.issuance.getAllIssuanceSessions({
projectId: 'clwt6e610000101s69ubga6lk',
})

Expand Down
2 changes: 1 addition & 1 deletion test/verificationSession.test.ts
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ dotenv.config()
describe('Verification Session', () => {
it('should return all issuance sessions', async () => {
const client = new Paradym({ apiKey: process.env.X_ACCESS_TOKEN as string })
const verificationSessions = await client.openId4Vc.verification.getAllOpenId4VcVerificationSessions({
const verificationSessions = await client.openId4Vc.verification.getAllVerificationSessions({
projectId: 'clwt6e610000101s69ubga6lk',
})

Expand Down

0 comments on commit 642bb76

Please sign in to comment.