Skip to content

feat(google-contacts): add google contacts integration#3340

Open
waleedlatif1 wants to merge 4 commits intostagingfrom
waleedlatif1/google-contacts
Open

feat(google-contacts): add google contacts integration#3340
waleedlatif1 wants to merge 4 commits intostagingfrom
waleedlatif1/google-contacts

Conversation

@waleedlatif1
Copy link
Collaborator

Summary

  • Add Google Contacts integration with create, get, list, search, update, delete operations
  • Register OAuth provider, trusted provider, and scope descriptions
  • Add block config with operation-based conditional fields
  • Generate docs

Type of Change

  • New feature

Testing

Tested manually

Checklist

  • Code follows project style guidelines
  • Self-reviewed my changes
  • Tests added/updated and passing
  • No new warnings introduced
  • I confirm that I have read and agree to the terms outlined in the Contributor License Agreement (CLA)

@vercel
Copy link

vercel bot commented Feb 25, 2026

The latest updates on your projects. Learn more about Vercel for GitHub.

Project Deployment Actions Updated (UTC)
docs Ready Ready Preview, Comment Feb 25, 2026 10:05pm

Request Review

@greptile-apps
Copy link
Contributor

greptile-apps bot commented Feb 25, 2026

Greptile Summary

This PR adds a complete Google Contacts integration following the established integration patterns in the codebase.

Key Changes:

  • Implemented six CRUD operations (create, get, list, search, update, delete) for Google Contacts using the People API
  • Registered OAuth provider with proper scopes (https://www.googleapis.com/auth/contacts)
  • Added block configuration with operation-based conditional fields
  • Generated comprehensive documentation

Implementation Quality:

  • Follows the codebase's integration checklist (tools → block → icon → OAuth setup)
  • Uses absolute imports as required by style guide
  • Proper type definitions with TypeScript interfaces
  • Consistent with existing Google integrations (Calendar, Drive, Docs)
  • Includes validation in update tool to ensure at least one field is provided
  • Properly handles OAuth token visibility as 'hidden'

Testing Note:
PR description indicates manual testing was performed, but no automated tests were added (checklist item marked incomplete)

Confidence Score: 5/5

  • This PR is safe to merge with minimal risk
  • The implementation follows all established patterns and conventions in the codebase. All six tools are properly structured, OAuth is correctly configured, types are well-defined, and registrations are complete. The code is consistent with existing Google integrations and adheres to the project's style guidelines.
  • No files require special attention

Important Files Changed

Filename Overview
apps/sim/tools/google_contacts/create.ts Added create contact tool with proper OAuth, params, request config, and response transformation
apps/sim/tools/google_contacts/update.ts Added update contact tool with validation to ensure at least one field is provided for update
apps/sim/tools/google_contacts/types.ts Defined all type interfaces and helper transformPerson function for contact metadata
apps/sim/blocks/blocks/google_contacts.ts Added block config with operation-based conditional fields, OAuth setup, and params type coercion
apps/sim/blocks/registry.ts Registered google_contacts block in alphabetical order
apps/sim/tools/registry.ts Registered all six Google Contacts tools in alphabetical order
apps/sim/lib/oauth/oauth.ts Added google-contacts OAuth provider config with proper scopes and getUserInfo implementation
apps/sim/lib/auth/auth.ts Registered google-contacts as trusted provider with OAuth configuration and user info handler

Flowchart

%%{init: {'theme': 'neutral'}}%%
flowchart TD
    A[Google Contacts Block] --> B{Operation Type}
    B -->|create| C[Create Tool]
    B -->|get| D[Get Tool]
    B -->|list| E[List Tool]
    B -->|search| F[Search Tool]
    B -->|update| G[Update Tool]
    B -->|delete| H[Delete Tool]
    
    C --> I[OAuth Provider]
    D --> I
    E --> I
    F --> I
    G --> I
    H --> I
    
    I --> J[Google People API]
    
    K[Block Registry] --> A
    L[Tool Registry] --> C
    L --> D
    L --> E
    L --> F
    L --> G
    L --> H
    
    M[Auth Config] --> I
    N[OAuth Config] --> I
Loading

Last reviewed commit: cfa3211

Copy link
Contributor

@greptile-apps greptile-apps bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

20 files reviewed, no comments

Edit Code Review Agent Settings | Greptile

@waleedlatif1
Copy link
Collaborator Author

@cursor review

@waleedlatif1
Copy link
Collaborator Author

@greptile

Copy link
Contributor

@greptile-apps greptile-apps bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

20 files reviewed, no comments

Edit Code Review Agent Settings | Greptile

Copy link

@cursor cursor bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

✅ Bugbot reviewed your changes and found no new issues!

Comment @cursor review or bugbot run to trigger another review on this PR

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant