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
Original file line number Diff line number Diff line change
Expand Up @@ -182,7 +182,7 @@ export class DiaBackendAssetRepository {
}

return this.httpClient.get<PaginatedResponse<DiaBackendAsset>>(
`${BASE_URL}/api/v2/assets/`,
`${BASE_URL}/api/v3/assets/`,
{ headers, params }
);
})
Expand All @@ -193,7 +193,7 @@ export class DiaBackendAssetRepository {
return defer(() => this.authService.getAuthHeaders()).pipe(
concatMap(headers =>
this.httpClient.get<DiaBackendAsset>(
`${BASE_URL}/api/v2/assets/${id}/`,
`${BASE_URL}/api/v3/assets/${id}/`,
{ headers }
)
)
Expand All @@ -206,7 +206,7 @@ export class DiaBackendAssetRepository {
return defer(() => this.authService.getAuthHeaders()).pipe(
concatMap(headers =>
this.httpClient.post(
`${BASE_URL}/api/v2/assets/${id}/download/`,
`${BASE_URL}/api/v3/assets/${id}/download/`,
formData,
{ headers, responseType: 'blob' }
)
Expand Down Expand Up @@ -236,7 +236,7 @@ export class DiaBackendAssetRepository {
]).pipe(
concatMap(([headers, formData]) =>
this.httpClient.patch<UpdateAssetResponse>(
`${BASE_URL}/api/v2/assets/${proof.diaBackendAssetId}/`,
`${BASE_URL}/api/v3/assets/${proof.diaBackendAssetId}/`,
formData,
{ headers }
)
Expand All @@ -251,7 +251,7 @@ export class DiaBackendAssetRepository {
return defer(() => this.authService.getAuthHeaders()).pipe(
concatMap(headers =>
this.httpClient.delete<DeleteAssetResponse>(
`${BASE_URL}/api/v2/assets/${id}/`,
`${BASE_URL}/api/v3/assets/${id}/`,
{ headers }
)
),
Expand All @@ -273,7 +273,7 @@ export class DiaBackendAssetRepository {
return defer(() => this.authService.getAuthHeadersWithApiKey()).pipe(
concatMap(headers => {
return this.httpClient.post(
`${BASE_URL}/api/v2/assets/${id}/mint/`,
`${BASE_URL}/api/v3/assets/${id}/mint/`,
formData,
{ headers }
);
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -130,8 +130,7 @@ export class DiaBackendAssetUploadingService {
return throwError(err);
}),
map(diaBackendAsset => {
// NOTE: need to change to diaBackendAsset.id when migrate to v3
proof.diaBackendAssetId = diaBackendAsset.uuid;
proof.diaBackendAssetId = diaBackendAsset.id;
return proof;
}),
retryWhen(err$ =>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -61,7 +61,7 @@ export class DiaBackendContactRepository {
return defer(() => this.authService.getAuthHeaders()).pipe(
concatMap(headers =>
this.httpClient.post<ContactDeleteResponse>(
`${BASE_URL}/api/v2/contacts/delete/`,
`${BASE_URL}/api/v3/contacts/delete/`,
{ email },
{ headers }
)
Expand Down Expand Up @@ -95,7 +95,7 @@ export class DiaBackendContactRepository {
}

return this.httpClient.get<PaginatedResponse<DiaBackendContact>>(
`${BASE_URL}/api/v2/contacts/`,
`${BASE_URL}/api/v3/contacts/`,
{ headers, params }
);
}),
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -46,7 +46,7 @@ export class DiaBackendSeriesRepository {
params = params.set('collected', `${collected}`);
}
return this.httpClient.get<PaginatedResponse<DiaBackendSeries>>(
`${BASE_URL}/api/v2/series/`,
`${BASE_URL}/api/v3/series/`,
{ headers, params }
);
})
Expand All @@ -57,7 +57,7 @@ export class DiaBackendSeriesRepository {
return defer(() => this.authService.getAuthHeaders()).pipe(
concatMap(headers =>
this.httpClient.get<DiaBackendSeries>(
`${BASE_URL}/api/v2/series/${id}/`,
`${BASE_URL}/api/v3/series/${id}/`,
{ headers }
)
)
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -116,7 +116,7 @@ export class DiaBackendTransactionRepository {
params = params.set('limit', `${limit}`);
}
return this.httpClient.get<PaginatedResponse<DiaBackendTransaction>>(
`${BASE_URL}/api/v2/transactions/inbox/`,
`${BASE_URL}/api/v3/transactions/inbox/`,
{ headers, params }
);
})
Expand All @@ -138,7 +138,7 @@ export class DiaBackendTransactionRepository {
}

return this.httpClient.get<PaginatedResponse<DiaBackendTransaction>>(
`${BASE_URL}/api/v2/transactions/`,
`${BASE_URL}/api/v3/transactions/`,
{ headers, params }
);
}),
Expand All @@ -150,7 +150,7 @@ export class DiaBackendTransactionRepository {
return defer(() => this.authService.getAuthHeaders()).pipe(
concatMap(headers =>
this.httpClient.get<DiaBackendTransaction>(
`${BASE_URL}/api/v2/transactions/${id}/`,
`${BASE_URL}/api/v3/transactions/${id}/`,
{ headers }
)
)
Expand All @@ -171,7 +171,7 @@ export class DiaBackendTransactionRepository {
return defer(() => this.authService.getAuthHeaders()).pipe(
concatMap(headers =>
this.httpClient.post<CreateTransactionResponse>(
`${BASE_URL}/api/v2/transactions/`,
`${BASE_URL}/api/v3/transactions/`,
{
asset_id: assetId,
email: targetEmail,
Expand All @@ -197,7 +197,7 @@ export class DiaBackendTransactionRepository {
return defer(() => this.authService.getAuthHeaders()).pipe(
concatMap(headers =>
this.httpClient.post<AcceptTransactionResponse>(
`${BASE_URL}/api/v2/transactions/${id}/accept/`,
`${BASE_URL}/api/v3/transactions/${id}/accept/`,
{},
{ headers }
)
Expand All @@ -214,7 +214,7 @@ export class DiaBackendTransactionRepository {
return defer(() => this.authService.getAuthHeaders()).pipe(
concatMap(headers =>
this.httpClient.post<AcceptTransactionResponse>(
`${BASE_URL}/api/v2/transactions/${id}/ignore/`,
`${BASE_URL}/api/v3/transactions/${id}/ignore/`,
{},
{ headers }
)
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,7 @@ export class DiaBackendWalletService {
return defer(() => this.authService.getAuthHeaders()).pipe(
concatMap(headers => {
return this.httpClient.get<DiaBackendWallet>(
`${BASE_URL}/api/v2/wallets/asset-wallet/`,
`${BASE_URL}/api/v3/wallets/asset-wallet/`,
{ headers }
);
})
Expand All @@ -43,7 +43,7 @@ export class DiaBackendWalletService {
const formData = new FormData();
formData.set('private_key', privateKey);
return this.httpClient.post<DiaBackendWallet>(
`${BASE_URL}/api/v2/wallets/asset-wallet/`,
`${BASE_URL}/api/v3/wallets/asset-wallet/`,
formData,
{ headers }
);
Expand All @@ -55,7 +55,7 @@ export class DiaBackendWalletService {
return defer(() => this.authService.getAuthHeaders()).pipe(
concatMap(headers => {
return this.httpClient.get<DiaBackendWallet>(
`${BASE_URL}/api/v2/wallets/managed-wallet/`,
`${BASE_URL}/api/v3/wallets/managed-wallet/`,
{ headers }
);
})
Expand Down