Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

🚑 Fix with new docker #359

Merged
merged 4 commits into from
Apr 17, 2024
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
34 changes: 27 additions & 7 deletions docker-compose.dev.yml
Original file line number Diff line number Diff line change
Expand Up @@ -66,8 +66,6 @@ services:
JIRA_SERVICE_MGMT_TICKETING_CLIENT_SECRET: ${JIRA_SERVICE_MGMT_TICKETING_CLIENT_SECRET}
LINEAR_TICKETING_CLIENT_ID: ${LINEAR_TICKETING_CLIENT_ID}
LINEAR_TICKETING_CLIENT_SECRET: ${LINEAR_TICKETING_CLIENT_SECRET}
AFFINITY_CRM_CLIENT_ID: ${AFFINITY_CRM_CLIENT_ID}
AFFINITY_CRM_CLIENT_SECRET: ${AFFINITY_CRM_CLIENT_SECRET}
ACCELO_CRM_CLIENT_ID: ${ACCELO_CRM_CLIENT_ID}
ACCELO_CRM_CLIENT_SECRET: ${ACCELO_CRM_CLIENT_SECRET}
ACCELO_CRM_SUBDOMAIN: ${ACCELO_CRM_SUBDOMAIN}
Expand All @@ -77,20 +75,42 @@ services:
CLOSE_CRM_CLIENT_SECRET: ${CLOSE_CRM_CLIENT_SECRET}
COPPER_CRM_CLIENT_ID: ${COPPER_CRM_CLIENT_ID}
COPPER_CRM_CLIENT_SECRET: ${COPPER_CRM_CLIENT_SECRET}
INSIGHTLY_CRM_CLIENT_ID: ${INSIGHTLY_CRM_CLIENT_ID}
INSIGHTLY_CRM_CLIENT_SECRET: ${INSIGHTLY_CRM_CLIENT_SECRET}
KEAP_CRM_CLIENT_ID: ${KEAP_CRM_CLIENT_ID}
KEAP_CRM_CLIENT_SECRET: ${KEAP_CRM_CLIENT_SECRET}
SUGARCRM_CRM_CLIENT_ID: ${SUGARCRM_CRM_CLIENT_ID}
SUGARCRM_CRM_CLIENT_SECRET: ${SUGARCRM_CRM_CLIENT_SECRET}
SUGARCRM_CRM_SUBDOMAIN: ${SUGARCRM_CRM_SUBDOMAIN}
TEAMLEADER_CRM_CLIENT_ID: ${TEAMLEADER_CRM_CLIENT_ID}
TEAMLEADER_CRM_CLIENT_SECRET: ${TEAMLEADER_CRM_CLIENT_SECRET}
TEAMWORK_CRM_CLIENT_ID: ${TEAMWORK_CRM_CLIENT_ID}
TEAMWORK_CRM_CLIENT_SECRET: ${TEAMWORK_CRM_CLIENT_SECRET}
AHA_TICKETING_CLIENT_ID: ${AHA_TICKETING_CLIENT_ID}
AHA_TICKETING_CLIENT_SECRET: ${AHA_TICKETING_CLIENT_SECRET}
AHA_TICKETING_SUBDOMAIN: ${AHA_TICKETING_SUBDOMAIN}
WRIKE_TICKETING_CLOUD_CLIENT_ID: ${WRIKE_TICKETING_CLOUD_CLIENT_ID}
WRIKE_TICKETING_CLOUD_CLIENT_SECRET: ${WRIKE_TICKETING_CLOUD_CLIENT_SECRET}
ASANA_TICKETING_CLOUD_CLIENT_ID: ${ASANA_TICKETING_CLOUD_CLIENT_ID}
ASANA_TICKETING_CLOUD_CLIENT_SECRET: ${ASANA_TICKETING_CLOUD_CLIENT_SECRET}
PENNYLANE_ACCOUNTING_CLOUD_CLIENT_ID: ${PENNYLANE_ACCOUNTING_CLOUD_CLIENT_ID}
PENNYLANE_ACCOUNTING_CLOUD_CLIENT_SECRET: ${PENNYLANE_ACCOUNTING_CLOUD_CLIENT_SECRET}
FRESHBOOKS_ACCOUNTING_CLOUD_CLIENT_ID: ${FRESHBOOKS_ACCOUNTING_CLOUD_CLIENT_ID}
FRESHBOOKS_ACCOUNTING_CLOUD_CLIENT_SECRET: ${FRESHBOOKS_ACCOUNTING_CLOUD_CLIENT_SECRET}
FREEAGENT_ACCOUNTING_CLOUD_CLIENT_ID: ${FREEAGENT_ACCOUNTING_CLOUD_CLIENT_ID}
FREEAGENT_ACCOUNTING_CLOUD_CLIENT_SECRET: ${FREEAGENT_ACCOUNTING_CLOUD_CLIENT_SECRET}
SAGE_ACCOUNTING_CLOUD_CLIENT_ID: ${SAGE_ACCOUNTING_CLOUD_CLIENT_ID}
SAGE_ACCOUNTING_CLOUD_CLIENT_SECRET: ${SAGE_ACCOUNTING_CLOUD_CLIENT_SECRET}
MONEYBIRD_ACCOUNTING_CLOUD_CLIENT_ID: ${MONEYBIRD_ACCOUNTING_CLOUD_CLIENT_ID}
MONEYBIRD_ACCOUNTING_CLOUD_CLIENT_SECRET: ${MONEYBIRD_ACCOUNTING_CLOUD_CLIENT_SECRET}
QUICKBOOKS_ACCOUNTING_CLOUD_CLIENT_ID: ${QUICKBOOKS_ACCOUNTING_CLOUD_CLIENT_ID}
QUICKBOOKS_ACCOUNTING_CLOUD_CLIENT_SECRET: ${QUICKBOOKS_ACCOUNTING_CLOUD_CLIENT_SECRET}
WAVE_FINANCIAL_ACCOUNTING_CLOUD_CLIENT_ID: ${WAVE_FINANCIAL_ACCOUNTING_CLOUD_CLIENT_ID}
WAVE_FINANCIAL_ACCOUNTING_CLOUD_CLIENT_SECRET: ${WAVE_FINANCIAL_ACCOUNTING_CLOUD_CLIENT_SECRET}
GETRESPONSE_MARKETING_AUTOMATION_CLOUD_CLIENT_ID: ${GETRESPONSE_MARKETING_AUTOMATION_CLOUD_CLIENT_ID}
GETRESPONSE_MARKETING_AUTOMATION_CLOUD_CLIENT_SECRET: ${GETRESPONSE_MARKETING_AUTOMATION_CLOUD_CLIENT_SECRET}
MAILCHIMP_MARKETING_AUTOMATION_CLOUD_CLIENT_ID: ${MAILCHIMP_MARKETING_AUTOMATION_CLOUD_CLIENT_ID}
MAILCHIMP_MARKETING_AUTOMATION_CLOUD_CLIENT_SECRET: ${MAILCHIMP_MARKETING_AUTOMATION_CLOUD_CLIENT_SECRET}
PODIUM_MARKETING_AUTOMATION_CLOUD_CLIENT_ID: ${PODIUM_MARKETING_AUTOMATION_CLOUD_CLIENT_ID}
PODIUM_MARKETING_AUTOMATION_CLOUD_CLIENT_SECRET: ${PODIUM_MARKETING_AUTOMATION_CLOUD_CLIENT_SECRET}



restart:
unless-stopped
ports:
Expand Down
37 changes: 29 additions & 8 deletions docker-compose.source.yml
Original file line number Diff line number Diff line change
Expand Up @@ -66,8 +66,6 @@ services:
JIRA_SERVICE_MGMT_TICKETING_CLIENT_SECRET: ${JIRA_SERVICE_MGMT_TICKETING_CLIENT_SECRET}
LINEAR_TICKETING_CLIENT_ID: ${LINEAR_TICKETING_CLIENT_ID}
LINEAR_TICKETING_CLIENT_SECRET: ${LINEAR_TICKETING_CLIENT_SECRET}
AFFINITY_CRM_CLIENT_ID: ${AFFINITY_CRM_CLIENT_ID}
AFFINITY_CRM_CLIENT_SECRET: ${AFFINITY_CRM_CLIENT_SECRET}
ACCELO_CRM_CLIENT_ID: ${ACCELO_CRM_CLIENT_ID}
ACCELO_CRM_CLIENT_SECRET: ${ACCELO_CRM_CLIENT_SECRET}
ACCELO_CRM_SUBDOMAIN: ${ACCELO_CRM_SUBDOMAIN}
Expand All @@ -77,20 +75,43 @@ services:
CLOSE_CRM_CLIENT_SECRET: ${CLOSE_CRM_CLIENT_SECRET}
COPPER_CRM_CLIENT_ID: ${COPPER_CRM_CLIENT_ID}
COPPER_CRM_CLIENT_SECRET: ${COPPER_CRM_CLIENT_SECRET}
INSIGHTLY_CRM_CLIENT_ID: ${INSIGHTLY_CRM_CLIENT_ID}
INSIGHTLY_CRM_CLIENT_SECRET: ${INSIGHTLY_CRM_CLIENT_SECRET}
KEAP_CRM_CLIENT_ID: ${KEAP_CRM_CLIENT_ID}
KEAP_CRM_CLIENT_SECRET: ${KEAP_CRM_CLIENT_SECRET}
SUGARCRM_CRM_CLIENT_ID: ${SUGARCRM_CRM_CLIENT_ID}
SUGARCRM_CRM_CLIENT_SECRET: ${SUGARCRM_CRM_CLIENT_SECRET}
SUGARCRM_CRM_SUBDOMAIN: ${SUGARCRM_CRM_SUBDOMAIN}
TEAMLEADER_CRM_CLIENT_ID: ${TEAMLEADER_CRM_CLIENT_ID}
TEAMLEADER_CRM_CLIENT_SECRET: ${TEAMLEADER_CRM_CLIENT_SECRET}
TEAMWORK_CRM_CLIENT_ID: ${TEAMWORK_CRM_CLIENT_ID}
TEAMWORK_CRM_CLIENT_SECRET: ${TEAMWORK_CRM_CLIENT_SECRET}
AHA_TICKETING_CLIENT_ID: ${AHA_TICKETING_CLIENT_ID}
AHA_TICKETING_CLIENT_SECRET: ${AHA_TICKETING_CLIENT_SECRET}
AHA_TICKETING_SUBDOMAIN: ${AHA_TICKETING_SUBDOMAIN}
AHA_TICKETING_SUBDOMAIN: ${AHA_TICKETING_SUBDOMAIN}
WRIKE_TICKETING_CLOUD_CLIENT_ID: ${WRIKE_TICKETING_CLOUD_CLIENT_ID}
WRIKE_TICKETING_CLOUD_CLIENT_SECRET: ${WRIKE_TICKETING_CLOUD_CLIENT_SECRET}
ASANA_TICKETING_CLOUD_CLIENT_ID: ${ASANA_TICKETING_CLOUD_CLIENT_ID}
ASANA_TICKETING_CLOUD_CLIENT_SECRET: ${ASANA_TICKETING_CLOUD_CLIENT_SECRET}
PENNYLANE_ACCOUNTING_CLOUD_CLIENT_ID: ${PENNYLANE_ACCOUNTING_CLOUD_CLIENT_ID}
PENNYLANE_ACCOUNTING_CLOUD_CLIENT_SECRET: ${PENNYLANE_ACCOUNTING_CLOUD_CLIENT_SECRET}
FRESHBOOKS_ACCOUNTING_CLOUD_CLIENT_ID: ${FRESHBOOKS_ACCOUNTING_CLOUD_CLIENT_ID}
FRESHBOOKS_ACCOUNTING_CLOUD_CLIENT_SECRET: ${FRESHBOOKS_ACCOUNTING_CLOUD_CLIENT_SECRET}
FREEAGENT_ACCOUNTING_CLOUD_CLIENT_ID: ${FREEAGENT_ACCOUNTING_CLOUD_CLIENT_ID}
FREEAGENT_ACCOUNTING_CLOUD_CLIENT_SECRET: ${FREEAGENT_ACCOUNTING_CLOUD_CLIENT_SECRET}
SAGE_ACCOUNTING_CLOUD_CLIENT_ID: ${SAGE_ACCOUNTING_CLOUD_CLIENT_ID}
SAGE_ACCOUNTING_CLOUD_CLIENT_SECRET: ${SAGE_ACCOUNTING_CLOUD_CLIENT_SECRET}
MONEYBIRD_ACCOUNTING_CLOUD_CLIENT_ID: ${MONEYBIRD_ACCOUNTING_CLOUD_CLIENT_ID}
MONEYBIRD_ACCOUNTING_CLOUD_CLIENT_SECRET: ${MONEYBIRD_ACCOUNTING_CLOUD_CLIENT_SECRET}
QUICKBOOKS_ACCOUNTING_CLOUD_CLIENT_ID: ${QUICKBOOKS_ACCOUNTING_CLOUD_CLIENT_ID}
QUICKBOOKS_ACCOUNTING_CLOUD_CLIENT_SECRET: ${QUICKBOOKS_ACCOUNTING_CLOUD_CLIENT_SECRET}
WAVE_FINANCIAL_ACCOUNTING_CLOUD_CLIENT_ID: ${WAVE_FINANCIAL_ACCOUNTING_CLOUD_CLIENT_ID}
WAVE_FINANCIAL_ACCOUNTING_CLOUD_CLIENT_SECRET: ${WAVE_FINANCIAL_ACCOUNTING_CLOUD_CLIENT_SECRET}
GETRESPONSE_MARKETING_AUTOMATION_CLOUD_CLIENT_ID: ${GETRESPONSE_MARKETING_AUTOMATION_CLOUD_CLIENT_ID}
GETRESPONSE_MARKETING_AUTOMATION_CLOUD_CLIENT_SECRET: ${GETRESPONSE_MARKETING_AUTOMATION_CLOUD_CLIENT_SECRET}
MAILCHIMP_MARKETING_AUTOMATION_CLOUD_CLIENT_ID: ${MAILCHIMP_MARKETING_AUTOMATION_CLOUD_CLIENT_ID}
MAILCHIMP_MARKETING_AUTOMATION_CLOUD_CLIENT_SECRET: ${MAILCHIMP_MARKETING_AUTOMATION_CLOUD_CLIENT_SECRET}
PODIUM_MARKETING_AUTOMATION_CLOUD_CLIENT_ID: ${PODIUM_MARKETING_AUTOMATION_CLOUD_CLIENT_ID}
PODIUM_MARKETING_AUTOMATION_CLOUD_CLIENT_SECRET: ${PODIUM_MARKETING_AUTOMATION_CLOUD_CLIENT_SECRET}




restart: unless-stopped
ports:
- 3000:3000
Expand Down
35 changes: 28 additions & 7 deletions docker-compose.yml
Original file line number Diff line number Diff line change
Expand Up @@ -61,8 +61,6 @@ services:
JIRA_SERVICE_MGMT_TICKETING_CLIENT_SECRET: ${JIRA_SERVICE_MGMT_TICKETING_CLIENT_SECRET}
LINEAR_TICKETING_CLIENT_ID: ${LINEAR_TICKETING_CLIENT_ID}
LINEAR_TICKETING_CLIENT_SECRET: ${LINEAR_TICKETING_CLIENT_SECRET}
AFFINITY_CRM_CLIENT_ID: ${AFFINITY_CRM_CLIENT_ID}
AFFINITY_CRM_CLIENT_SECRET: ${AFFINITY_CRM_CLIENT_SECRET}
ACCELO_CRM_CLIENT_ID: ${ACCELO_CRM_CLIENT_ID}
ACCELO_CRM_CLIENT_SECRET: ${ACCELO_CRM_CLIENT_SECRET}
ACCELO_CRM_SUBDOMAIN: ${ACCELO_CRM_SUBDOMAIN}
Expand All @@ -72,20 +70,43 @@ services:
CLOSE_CRM_CLIENT_SECRET: ${CLOSE_CRM_CLIENT_SECRET}
COPPER_CRM_CLIENT_ID: ${COPPER_CRM_CLIENT_ID}
COPPER_CRM_CLIENT_SECRET: ${COPPER_CRM_CLIENT_SECRET}
INSIGHTLY_CRM_CLIENT_ID: ${INSIGHTLY_CRM_CLIENT_ID}
INSIGHTLY_CRM_CLIENT_SECRET: ${INSIGHTLY_CRM_CLIENT_SECRET}
KEAP_CRM_CLIENT_ID: ${KEAP_CRM_CLIENT_ID}
KEAP_CRM_CLIENT_SECRET: ${KEAP_CRM_CLIENT_SECRET}
SUGARCRM_CRM_CLIENT_ID: ${SUGARCRM_CRM_CLIENT_ID}
SUGARCRM_CRM_CLIENT_SECRET: ${SUGARCRM_CRM_CLIENT_SECRET}
SUGARCRM_CRM_SUBDOMAIN: ${SUGARCRM_CRM_SUBDOMAIN}
TEAMLEADER_CRM_CLIENT_ID: ${TEAMLEADER_CRM_CLIENT_ID}
TEAMLEADER_CRM_CLIENT_SECRET: ${TEAMLEADER_CRM_CLIENT_SECRET}
TEAMWORK_CRM_CLIENT_ID: ${TEAMWORK_CRM_CLIENT_ID}
TEAMWORK_CRM_CLIENT_SECRET: ${TEAMWORK_CRM_CLIENT_SECRET}
AHA_TICKETING_CLIENT_ID: ${AHA_TICKETING_CLIENT_ID}
AHA_TICKETING_CLIENT_SECRET: ${AHA_TICKETING_CLIENT_SECRET}
AHA_TICKETING_SUBDOMAIN: ${AHA_TICKETING_SUBDOMAIN}
WRIKE_TICKETING_CLOUD_CLIENT_ID: ${WRIKE_TICKETING_CLOUD_CLIENT_ID}
WRIKE_TICKETING_CLOUD_CLIENT_SECRET: ${WRIKE_TICKETING_CLOUD_CLIENT_SECRET}
ASANA_TICKETING_CLOUD_CLIENT_ID: ${ASANA_TICKETING_CLOUD_CLIENT_ID}
ASANA_TICKETING_CLOUD_CLIENT_SECRET: ${ASANA_TICKETING_CLOUD_CLIENT_SECRET}
PENNYLANE_ACCOUNTING_CLOUD_CLIENT_ID: ${PENNYLANE_ACCOUNTING_CLOUD_CLIENT_ID}
PENNYLANE_ACCOUNTING_CLOUD_CLIENT_SECRET: ${PENNYLANE_ACCOUNTING_CLOUD_CLIENT_SECRET}
FRESHBOOKS_ACCOUNTING_CLOUD_CLIENT_ID: ${FRESHBOOKS_ACCOUNTING_CLOUD_CLIENT_ID}
FRESHBOOKS_ACCOUNTING_CLOUD_CLIENT_SECRET: ${FRESHBOOKS_ACCOUNTING_CLOUD_CLIENT_SECRET}
FREEAGENT_ACCOUNTING_CLOUD_CLIENT_ID: ${FREEAGENT_ACCOUNTING_CLOUD_CLIENT_ID}
FREEAGENT_ACCOUNTING_CLOUD_CLIENT_SECRET: ${FREEAGENT_ACCOUNTING_CLOUD_CLIENT_SECRET}
SAGE_ACCOUNTING_CLOUD_CLIENT_ID: ${SAGE_ACCOUNTING_CLOUD_CLIENT_ID}
SAGE_ACCOUNTING_CLOUD_CLIENT_SECRET: ${SAGE_ACCOUNTING_CLOUD_CLIENT_SECRET}
MONEYBIRD_ACCOUNTING_CLOUD_CLIENT_ID: ${MONEYBIRD_ACCOUNTING_CLOUD_CLIENT_ID}
MONEYBIRD_ACCOUNTING_CLOUD_CLIENT_SECRET: ${MONEYBIRD_ACCOUNTING_CLOUD_CLIENT_SECRET}
QUICKBOOKS_ACCOUNTING_CLOUD_CLIENT_ID: ${QUICKBOOKS_ACCOUNTING_CLOUD_CLIENT_ID}
QUICKBOOKS_ACCOUNTING_CLOUD_CLIENT_SECRET: ${QUICKBOOKS_ACCOUNTING_CLOUD_CLIENT_SECRET}
WAVE_FINANCIAL_ACCOUNTING_CLOUD_CLIENT_ID: ${WAVE_FINANCIAL_ACCOUNTING_CLOUD_CLIENT_ID}
WAVE_FINANCIAL_ACCOUNTING_CLOUD_CLIENT_SECRET: ${WAVE_FINANCIAL_ACCOUNTING_CLOUD_CLIENT_SECRET}
GETRESPONSE_MARKETING_AUTOMATION_CLOUD_CLIENT_ID: ${GETRESPONSE_MARKETING_AUTOMATION_CLOUD_CLIENT_ID}
GETRESPONSE_MARKETING_AUTOMATION_CLOUD_CLIENT_SECRET: ${GETRESPONSE_MARKETING_AUTOMATION_CLOUD_CLIENT_SECRET}
MAILCHIMP_MARKETING_AUTOMATION_CLOUD_CLIENT_ID: ${MAILCHIMP_MARKETING_AUTOMATION_CLOUD_CLIENT_ID}
MAILCHIMP_MARKETING_AUTOMATION_CLOUD_CLIENT_SECRET: ${MAILCHIMP_MARKETING_AUTOMATION_CLOUD_CLIENT_SECRET}
PODIUM_MARKETING_AUTOMATION_CLOUD_CLIENT_ID: ${PODIUM_MARKETING_AUTOMATION_CLOUD_CLIENT_ID}
PODIUM_MARKETING_AUTOMATION_CLOUD_CLIENT_SECRET: ${PODIUM_MARKETING_AUTOMATION_CLOUD_CLIENT_SECRET}




restart:
unless-stopped
ports:
Expand Down
1 change: 1 addition & 0 deletions packages/api/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -111,3 +111,4 @@
"testEnvironment": "node"
}
}

24 changes: 12 additions & 12 deletions packages/api/scripts/oauthConnector.js
Original file line number Diff line number Diff line change
Expand Up @@ -56,7 +56,8 @@ import { ConnectionsStrategiesService } from '@@core/connections-strategies/conn
export type ${providerUpper}OAuthResponse = {
access_token: string;
refresh_token: string;
expires_at: string;
expires_in: string;
token_type: string;
};

@Injectable()
Expand Down Expand Up @@ -126,7 +127,7 @@ export class ${providerUpper}ConnectionService implements I${verticalUpper}Conne
refresh_token: this.cryptoService.encrypt(data.refresh_token),
account_url: "",
expiration_timestamp: new Date(
new Date().getTime() + Number(data.expires_at) * 1000,
new Date().getTime() + Number(data.expires_in) * 1000,
),
status: 'valid',
created_at: new Date(),
Expand All @@ -144,7 +145,7 @@ export class ${providerUpper}ConnectionService implements I${verticalUpper}Conne
access_token: this.cryptoService.encrypt(data.access_token),
refresh_token: this.cryptoService.encrypt(data.refresh_token),
expiration_timestamp: new Date(
new Date().getTime() + Number(data.expires_at) * 1000,
new Date().getTime() + Number(data.expires_in) * 1000,
),
status: 'valid',
created_at: new Date(),
Expand All @@ -165,16 +166,15 @@ export class ${providerUpper}ConnectionService implements I${verticalUpper}Conne

async handleTokenRefresh(opts: RefreshParams) {
try {
const { connectionId, refreshToken } = opts;
const formData = new URLSearchParams({
grant_type: 'refresh_token',
refresh_token: this.cryptoService.decrypt(refreshToken),
});
const { connectionId, refreshToken, projectId } = opts;
const CREDENTIALS = (await this.cService.getCredentials(
projectId,
this.type,
)) as OAuth2AuthData;

const formData = new URLSearchParams({
grant_type: 'refresh_token',
refresh_token: this.cryptoService.decrypt(refreshToken),
});
const res = await axios.post(
"",
formData.toString(),
Expand All @@ -198,7 +198,7 @@ export class ${providerUpper}ConnectionService implements I${verticalUpper}Conne
access_token: this.cryptoService.encrypt(data.access_token),
refresh_token: this.cryptoService.encrypt(data.refresh_token),
expiration_timestamp: new Date(
new Date().getTime() + Number(data.expires_at) * 1000,
new Date().getTime() + Number(data.expires_in) * 1000,
),
},
});
Expand Down Expand Up @@ -286,7 +286,7 @@ function addProviderToDockerCompose(provider, vertical, dockerComposePath) {

function handleUpdate(vertical, provider) {
createServiceFile(vertical, provider);
addProviderToEnvironmentService(provider, envServiceFilePath);
//addProviderToEnvironmentService(provider, envServiceFilePath);
for (const path of paths) {
addProviderToDockerCompose(provider, vertical, path);
}
Expand All @@ -298,7 +298,7 @@ if (import.meta.url === process.argv[1]) {
const vertical = args[0];
const provider = args[1];
createServiceFile(vertical, provider);
addProviderToEnvironmentService(provider, envServiceFilePath);
//addProviderToEnvironmentService(provider, envServiceFilePath);
for (const path of paths) {
addProviderToDockerCompose(argv.provider, path);
}
Expand Down
Original file line number Diff line number Diff line change
@@ -0,0 +1,41 @@
import { Module } from '@nestjs/common';
import { PrismaService } from '@@core/prisma/prisma.service';
import { LoggerService } from '@@core/logger/logger.service';
import { WebhookService } from '@@core/webhook/webhook.service';
import { WebhookModule } from '@@core/webhook/webhook.module';
import { EnvironmentService } from '@@core/environment/environment.service';
import { EncryptionService } from '@@core/encryption/encryption.service';
import { ConnectionsStrategiesService } from '@@core/connections-strategies/connections-strategies.service';
import { ServiceRegistry } from './services/registry.service';
import { AccountingConnectionsService } from './services/accounting.connection.service';
import { PennylaneConnectionService } from './services/pennylane/pennylane.service';
import { FreeagentConnectionService } from './services/freeagent/freeagent.service';
import { FreshbooksConnectionService } from './services/freshbooks/freshbooks.service';
import { MoneybirdConnectionService } from './services/moneybird/moneybird.service';
import { QuickbooksConnectionService } from './services/quickbooks/quickbooks.service';
import { SageConnectionService } from './services/sage/sage.service';
import { WaveFinancialConnectionService } from './services/wave_financial/wave_financial.service';

@Module({
imports: [WebhookModule],
providers: [
AccountingConnectionsService,
PrismaService,
LoggerService,
WebhookService,
EnvironmentService,
EncryptionService,
ServiceRegistry,
ConnectionsStrategiesService,
//PROVIDERS SERVICES,
PennylaneConnectionService,
FreeagentConnectionService,
FreshbooksConnectionService,
MoneybirdConnectionService,
QuickbooksConnectionService,
SageConnectionService,
WaveFinancialConnectionService,
],
exports: [AccountingConnectionsService],
})
export class AccountingConnectionModule {}
Loading
Loading