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
26 changes: 0 additions & 26 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -96,11 +96,6 @@ ___
| [show-context](#binding-show-context) | Show current extension section context.
| [clear-context](#binding-clear-context) | Clear current extension section context.

### Partner Commands
| Command | Description |
| ------------- |-------------|
| [connect](#partner-connect) | Add partner access token so that you don't need to add it explicitly |

### Config Commands

| Command Type | Description |
Expand Down Expand Up @@ -611,27 +606,6 @@ This command will allow developers to clear the current extension section contex
```sh
fdk binding clear-context
```

### Partner Commands

<div id="partner-connect"></div>

#### connect
This command is used to add your partner access token to update extension details on partners panel.
#### **Syntax**
```sh
fdk partner connect [options]
```
#### **Command Options**
| Option | Description |
| ------------- |-------------|
| --help | Show help |
| --verbose, -v | enable debug mode |

#### **Example**
```sh
fdk partner connect
```
___
### Config Commands
<div id="config-commands"></div>
Expand Down
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "@gofynd/fdk-cli",
"version": "6.2.7",
"version": "7.0.0",
"main": "index.js",
"license": "MIT",
"bin": {
Expand Down
3 changes: 0 additions & 3 deletions src/__tests__/previewUrlExtension.spec.ts
Original file line number Diff line number Diff line change
Expand Up @@ -122,9 +122,6 @@ describe('Extension preview-url command', () => {
// mock axios
mockAxios = new MockAdapter(axios);
mockCustomAxios = new MockAdapter(withoutErrorResponseInterceptorAxios);
mockAxios
.onPost(`${URLS.VALIDATE_ACCESS_TOKEN()}`)
.reply(200, { id: ORGANIZATION_ID });

mockAxios
.onGet(`${URLS.GET_DEVELOPMENT_ACCOUNTS(1, 9999)}`)
Expand Down
1 change: 0 additions & 1 deletion src/commands/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,6 @@ const COMMANDS = [
require('./populate'),
require('./tunnel'),
require('./extension'),
require('./partner'),
require('./binding'),
require('./config'),
];
Expand Down
13 changes: 0 additions & 13 deletions src/commands/partner.ts

This file was deleted.

6 changes: 0 additions & 6 deletions src/fdk.ts
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,6 @@ import {
AUTHENTICATION_COMMANDS,
ENVIRONMENT_COMMANDS,
EXTENSION_COMMANDS,
PARTNER_COMMANDS,
ALL_THEME_COMMANDS,
} from './helper/constants';
import { getPlatformUrls } from './lib/api/services/url';
Expand Down Expand Up @@ -170,11 +169,6 @@ Command.prototype.asyncAction = async function (asyncFn: Action) {
extensionCommand.includes(c),
) !== -1
) &&
!(
PARTNER_COMMANDS.findIndex((c) =>
partnerCommand.includes(c),
) !== -1
) &&
!configStore.get(CONFIG_KEYS.AUTH_TOKEN)
) {
throw new CommandError(COMMON_LOG_MESSAGES.RequireAuth);
Expand Down
1 change: 0 additions & 1 deletion src/helper/constants.ts
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,6 @@ export const ENVIRONMENT_COMMANDS = ['env'];
export const AUTHENTICATION_COMMANDS = ['auth', 'login', 'logout'];
export const EXTENSION_COMMANDS = ['init', 'get', 'set', 'pull-env'];
export const MAX_RETRY = 5;
export const PARTNER_COMMANDS = ['connect'];
export const THEME_TYPE = {
vue2: 'vue2',
react: 'react',
Expand Down
2 changes: 1 addition & 1 deletion src/helper/download.ts
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@ export async function downloadFile(url: string, filePath: string) {

response.data.pipe(writer);

return new Promise((resolve, reject) => {
return new Promise<void>((resolve, reject) => {
writer.on('finish', resolve);
writer.on('error', reject);
});
Expand Down
57 changes: 0 additions & 57 deletions src/lib/Partner.ts

This file was deleted.

24 changes: 0 additions & 24 deletions src/lib/api/services/extension.service.ts
Original file line number Diff line number Diff line change
Expand Up @@ -106,30 +106,6 @@ export default {
}
},

validateAccessToken: async (partner_access_token: string) => {
try {
let headers = getCommonHeaderOptions().headers;

let axiosOptions = Object.assign(
{},
{
data: { token: partner_access_token },
},
{
headers: headers,
},
);
let response = await ApiClient.post(
URLS.VALIDATE_ACCESS_TOKEN(),
axiosOptions,
);
response.data.partner_access_token = partner_access_token;
return response.data;
} catch (err) {
throw err;
}
},

// Preview URL
getDevelopmentAccounts: async (page_no: number, page_size: number) => {
try {
Expand Down
7 changes: 0 additions & 7 deletions src/lib/api/services/url.ts
Original file line number Diff line number Diff line change
Expand Up @@ -173,13 +173,6 @@ export const URLS = {
);
},

VALIDATE_ACCESS_TOKEN: (): string => {
return urlJoin(
MIXMASTER_URL('partner'),
`organization/${getOrganizationId()}/accesstoken/validate`,
);
},

// Extension Section
PUBLISH_SECTIONS: (extension_id: string, organization_id) => {
return urlJoin(
Expand Down
Loading