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
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
{
"name": "@internxt/sdk",
"author": "Internxt <[email protected]>",
"version": "1.9.5",
"version": "1.9.6",
"description": "An sdk for interacting with Internxt's services",
"repository": {
"type": "git",
Expand Down
8 changes: 6 additions & 2 deletions src/drive/users/types.ts
Original file line number Diff line number Diff line change
Expand Up @@ -37,13 +37,17 @@ export type UpdateProfilePayload = Partial<Pick<UserSettings, 'name' | 'lastname

export type PreCreateUserResponse = {
publicKey: string;
publicKyberKey?: string;
keys?:
{
ecc: string;
kyber: string;
};
user: { uuid: UUID; email: string };
};

export type FriendInvite = { guestEmail: string; host: number; accepted: boolean; id: number };

export type UserPublicKeyResponse = { publicKey: string; publicKyberKey?: string };
export type UserPublicKeyResponse = { publicKey: string; keys?: { ecc:string; kyber: string}; };

export type VerifyEmailChangeResponse = {
oldEmail: string;
Expand Down
10 changes: 8 additions & 2 deletions test/drive/users/index.test.ts
Original file line number Diff line number Diff line change
Expand Up @@ -100,7 +100,10 @@ describe('# users service tests', () => {
const email = '[email protected]';
const callStub = sinon.stub(httpClient, 'post').resolves({
publicKey: 'publicKey',
publicKyberKey: 'publicKeyberKey',
keys: {
kyber: 'publicKeyberKey',
ecc: 'publicKey',
},
user: { uuid: 'exampleUuid', email },
});

Expand All @@ -111,7 +114,10 @@ describe('# users service tests', () => {
expect(callStub.firstCall.args).toEqual(['/users/pre-create', { email }, headers]);
expect(body).toEqual({
publicKey: 'publicKey',
publicKyberKey: 'publicKeyberKey',
keys: {
kyber: 'publicKeyberKey',
ecc: 'publicKey',
},
user: { uuid: 'exampleUuid', email },
});
});
Expand Down