So, how to connect Lark with ChatGPT?

So, how to connect Lark with ChatGPT?

Portrait of Jess Cheung Lark's Author
Portrait of Jess Cheung Lark's Author

Jess Cheung

June 9, 2023

6/9/23

Jun 9, 2023

6/9/23

6 min read

What makes a company competitive? There are various answers to this question, but one thing is certain: in 2023, businesses that can harness the power of artificial intelligence (AI) will have a greater chance of success.

As ChatGPT changes the way the workforce operates, it's necessary to rethink productivity in our era. By integrating ChatGPT with Lark, you can easily improve work efficiency. This blog will guide you through five simple steps to connect ChatGPT with Lark.

Benefits of using ChatGPT in Lark for work

Linking ChatGPT to Lark can provide numerous benefits for your work, such as:

  1. Reduce the need to toggle between web pages and your Lark app. With ChatGPT in Lark, you no longer have to juggle work and switch between different apps or web pages to get the information you need. This saves you time and helps you stay focused.

  2. Your workflow and thought process won't be disrupted. You can immediately start working after chatting with GPT in Lark. ChatGPT allows you to seamlessly integrate AI into your workflow without interrupting your thought process.

  3. Make your collaboration smoother by inviting ChatGPT as one of your team members for activities such as brainstorming and discussion. ChatGPT can join your team and provide valuable input during collaboration activities.

5 steps to connect ChatGPT with Lark

1. Register for a Lark tenant

If you haven't registered your business for a Lark tenant, you can sign up for free at https://www.larksuite.com/. As ChatGPT is a conversation-based artificial intelligence, it is good practice to invite all your team members into Lark once registration is complete. This will allow ChatGPT to be useful for your whole business.

2. Register for a free OpenAI account and get a secret key

Next, go to https://openai.com/ and click "Sign up" in the top right corner of the page, and use an email address and mobile phone number that you can consistently access to register.

After logging in, select "API" and generate a secret key. Make sure to copy and save the secret key in a safe place, as it will only be displayed once.

3. Build your custom application on Lark Open Platform

To get started, log in to your Lark account and go to the Lark Open Platform. Click “CREATE APP”, and set up your app name and profile photo. Then, in the developer console, turn on the bot feature for this custom app. You can always change the app name and the profile photo later on.

4. Time to Code

To initiate a chat with ChatGPT on Lark, you must first ensure that your message is successfully sent to OpenAI, which will then provide a response. This can be achieved by setting up a request URL in the bot feature for the custom application you create on Lark Open Platform. To build this URL, you can go to a Function-as-a-Service platform you are familiar with to create it. When coding, make sure to include the required dependencies and correct keys as highlighted below.

You can find the App ID, App Secret, and the name of your custom application in Lark Developer Console by going to the Credentials & Basic Info page. And now it’s time to paste in the Secret Key from OpenAI you get in step 2.

  • APPID = Lark custom application’s app ID

  • SECRET = Lark custom application’s app secret

  • BOTNAME = The name of your Lark custom application (in our case, it’s called “Larkie Enterprise GPT”)

  • KEY = The secret key from your OpenAI account

5. Turn the needed permissions on, paste in your request URL, and launch 🚀

Once you've tested your code, copy the request URL from AirCode and paste it into your custom application, under Features - Bot - Bot Setting.

When building the request URL, make sure you add the needed dependencies and keys, such as app ID, secret key, and bot name.

Before you officially launch the bot, make sure you tick the permissions you need to give OpenAI in order for it to read and respond to messages from 1:1 and group chats on Lark. Depending on how you want to use ChatGPT in other tasks, you might need to turn on permissions for it to read Calendar, Docs, and more.

On Lark Open Platform, you can turn on the relevant permissions across docs, chats, sheets, Base, and more in order for OpenAI to read the information it needs to react to.

Then, sit tight and click “Submit for Release”. Once it’s approved by the assigned approvers in Lark, you can start using AI for your work.

What you need to know before connecting ChatGPT with Lark: 3 starter tips

There are several benefits to using ChatGPT for work, but we understand that it's not always a case of "the more, the merrier." To make the most of your developer resources and ChatGPT's strengths, here are some tips when integrating it with Lark:

  1. Clearly define what you want ChatGPT to do. This will help you quickly set up the necessary permissions in Lark's open platform and ensure a smooth experience. Make sure to check all the boxes before launching your 1.0.0.


  2. Understand the pros and cons of ChatGPT and set appropriate expectations. While ChatGPT can be a great tool for brainstorming, summarizing long texts and large sets of numbers, and improving your writing, it has limitations. For example, it's not good at fact-checking and may provide fake links and references.


  3. Understand your business's data and security requirements to ensure that you can use ChatGPT without risking data breaches. Before adding ChatGPT to your Lark toolbox, it's important to review your company's security policies and data regulations and consult relevant teams, such as legal and IT, for approval.


Interested in starting today? Get Lark for your business and start building your first AI-powered custom application easily ↓

Pay less to get more today

No more redundant tools. Save time and costs.

Product

Pricing

Alternatives

Compare

Solutions

Use Cases

Resources

Templates

Security

Join Us

Build with Us

Language

English

© 2024 Lark Technologies Pte. Ltd.
Headquartered in Singapore with offices worldwide.

Product

Pricing

Alternatives

Compare

Solutions

Use Cases

Resources

Templates

Security

Join Us

Build with Us

Language

English

© 2024 Lark Technologies Pte. Ltd.
Headquartered in Singapore with offices worldwide.