You Have No Excuse Now – Deepseek API is Now 100% FREE To Use 🚀 Build AI Apps and Chatbots

3 min read 1 month ago
Published on Jun 08, 2025 This response is partially generated with the help of AI. It may contain inaccuracies.

Introduction

In this tutorial, you'll learn how to access and utilize the Deepseek AI API for free, allowing you to build powerful chatbots and AI applications. This guide provides step-by-step instructions on obtaining your API key, integrating it into your projects, and testing your applications using the Veo code editor. Whether you're a seasoned developer or just starting out, this is a valuable resource to enhance your web development capabilities with cutting-edge AI technology.

Step 1: Create Your Deepseek API Key

  • Visit the OpenRouter website at OpenRouter.
  • Sign up for a free account if you don't already have one.
  • After logging in, navigate to the API section.
  • Request your Deepseek R01 API key, which is free for lifetime access.
  • Save the API key securely, as you will need it for integration.

Step 2: Access Deepseek on OpenRouter

  • Make sure you are logged into your OpenRouter account.
  • Familiarize yourself with the API documentation provided on the site.
  • Understand the key endpoints and functionalities available for the Deepseek API to better utilize its features.

Step 3: Set Up Your Development Environment

  • Download and install the Veo code editor or any preferred IDE that supports TypeScript or Python.
  • If using TypeScript, ensure you have Node.js installed.
  • Set up a new project in your code editor to start building your AI application.

Step 4: Integrate the Deepseek API

For TypeScript

  1. In your project folder, run the following command to install Axios for API requests:
    npm install axios
    
  2. Create a new file, e.g., chatbot.ts, and import Axios:
    import axios from 'axios';
    
  3. Set up the API call:
    const apiKey = 'YOUR_DEEPSEEK_API_KEY'; // Replace with your actual API key
    
    async function fetchResponse(input: string) {
        const response = await axios.post('https://api.deepseek.ai/endpoint', {
            prompt: input,
            key: apiKey
        });
        return response.data;
    }
    

For Python

  1. Install the requests library if you haven't already:
    pip install requests
    
  2. Create a new Python file, e.g., chatbot.py, and import requests:
    import requests
    
  3. Set up the API call:
    api_key = 'YOUR_DEEPSEEK_API_KEY'  # Replace with your actual API key
    
    

    def fetch_response(input_text)

    response = requests.post('https://api.deepseek.ai/endpoint', json={ 'prompt': input_text, 'key': api_key }) return response.json()

Step 5: Test Your AI Chatbot or Application

  • Implement a simple user input system to test the functionality of your chatbot.
  • For TypeScript, you may use console.log for outputs.
  • For Python, utilize print() for displaying responses.
  • Run your application and input a prompt to see how the Deepseek API responds.

Conclusion

Congratulations! You have successfully set up the Deepseek API and tested your first AI-powered application. By following these steps, you can leverage the capabilities of Deepseek to create advanced chatbots and web applications without any costs. Explore further by experimenting with different prompts and functionalities provided by the API. Keep enhancing your skills in AI development and consider integrating more features as you grow more comfortable with the tools available.