Skip to content
Original file line number Diff line number Diff line change
Expand Up @@ -57,6 +57,7 @@ export function AddConnectorModal({ open, onOpenChange, knowledgeBaseId }: AddCo
const [showOAuthModal, setShowOAuthModal] = useState(false)

const [apiKeyValue, setApiKeyValue] = useState('')
const [apiKeyFocused, setApiKeyFocused] = useState(false)
const [searchTerm, setSearchTerm] = useState('')
Comment thread
waleedlatif1 marked this conversation as resolved.

const { workspaceId } = useParams<{ workspaceId: string }>()
Expand Down Expand Up @@ -235,10 +236,12 @@ export function AddConnectorModal({ open, onOpenChange, knowledgeBaseId }: AddCo
: 'API Key'}
</Label>
<Input
type='password'
type={apiKeyFocused ? 'text' : 'password'}
autoComplete='new-password'
value={apiKeyValue}
onChange={(e) => setApiKeyValue(e.target.value)}
onFocus={() => setApiKeyFocused(true)}
onBlur={() => setApiKeyFocused(false)}
placeholder={
connectorConfig.auth.mode === 'apiKey' && connectorConfig.auth.placeholder
? connectorConfig.auth.placeholder
Expand Down Expand Up @@ -345,17 +348,7 @@ export function AddConnectorModal({ open, onOpenChange, knowledgeBaseId }: AddCo
>
<Checkbox
checked={!disabledTagIds.has(tagDef.id)}
onCheckedChange={(checked) => {
setDisabledTagIds((prev) => {
const next = new Set(prev)
if (checked) {
next.delete(tagDef.id)
} else {
next.add(tagDef.id)
}
return next
})
}}
onCheckedChange={() => {}}
/>
Comment thread
waleedlatif1 marked this conversation as resolved.
<span className='text-[var(--text-primary)]'>{tagDef.displayName}</span>
<span className='text-[11px] text-[var(--text-muted)]'>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -130,8 +130,6 @@ export function ConnectorsSection({

return (
<div className='mt-[16px]'>
<h2 className='font-medium text-[14px] text-[var(--text-secondary)]'>Connected Sources</h2>

{error && (
<p className='mt-[8px] text-[12px] text-[var(--text-error)] leading-tight'>{error}</p>
)}
Expand Down
6 changes: 5 additions & 1 deletion apps/sim/connectors/github/github.ts
Original file line number Diff line number Diff line change
Expand Up @@ -158,7 +158,11 @@ export const githubConnector: ConnectorConfig = {
version: '1.0.0',
icon: GithubIcon,

auth: { mode: 'oauth', provider: 'github', requiredScopes: ['repo'] },
auth: {
mode: 'apiKey',
label: 'Personal Access Token',
placeholder: 'ghp_xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx',
},

configFields: [
{
Expand Down
2 changes: 1 addition & 1 deletion apps/sim/connectors/gmail/gmail.ts
Original file line number Diff line number Diff line change
Expand Up @@ -291,7 +291,7 @@ export const gmailConnector: ConnectorConfig = {
auth: {
mode: 'oauth',
provider: 'google-email',
requiredScopes: ['https://www.googleapis.com/auth/gmail.readonly'],
requiredScopes: ['https://www.googleapis.com/auth/gmail.modify'],
Comment thread
waleedlatif1 marked this conversation as resolved.
},

configFields: [
Expand Down
2 changes: 1 addition & 1 deletion apps/sim/connectors/google-calendar/google-calendar.ts
Original file line number Diff line number Diff line change
Expand Up @@ -237,7 +237,7 @@ export const googleCalendarConnector: ConnectorConfig = {
auth: {
mode: 'oauth',
provider: 'google-calendar',
requiredScopes: ['https://www.googleapis.com/auth/calendar.readonly'],
requiredScopes: ['https://www.googleapis.com/auth/calendar'],
Comment thread
waleedlatif1 marked this conversation as resolved.
},

configFields: [
Expand Down
2 changes: 1 addition & 1 deletion apps/sim/connectors/google-sheets/google-sheets.ts
Original file line number Diff line number Diff line change
Expand Up @@ -171,7 +171,7 @@ export const googleSheetsConnector: ConnectorConfig = {
auth: {
mode: 'oauth',
provider: 'google-sheets',
requiredScopes: ['https://www.googleapis.com/auth/spreadsheets.readonly'],
requiredScopes: ['https://www.googleapis.com/auth/drive'],
Comment thread
waleedlatif1 marked this conversation as resolved.
},

configFields: [
Expand Down
1 change: 1 addition & 0 deletions apps/sim/connectors/reddit/reddit.ts
Original file line number Diff line number Diff line change
Expand Up @@ -241,6 +241,7 @@ export const redditConnector: ConnectorConfig = {
auth: {
mode: 'oauth',
provider: 'reddit',
requiredScopes: ['read'],
},

configFields: [
Expand Down
Loading