Skip to main content

An MCP server for Pexels

Project description

Pexels MCP Server

A Model Context Protocol server that provides access to the Pexels API for searching and retrieving photos, videos, and collections.

Available Tools

  • photos_search – Search photos
  • photos_curated – List curated photos
  • photo_get – Get a photo by id
  • videos_search – Search videos
  • videos_popular – List popular videos
  • video_get – Get a video by id
  • collections_featured – List featured collections
  • collections_media – List media in a collection

Usage

Using uv (recommended)

  1. Install uv.

  2. In your MCP client code configuration or Claude settings (file claude_desktop_config.json) add pexels mcp server:

    {
        "mcpServers": {
            "pexels": {
                "command": "uvx",
                "args": ["pexels-mcp-server"],
                "env": {
                    "PEXELS_API_KEY": "<Your Pexels API key>"
                }
            }
        }
    }
    

    uv will download the MCP server automatically using uvx from pypi.org and apply to your MCP client.

Using pip for a project

  1. Add pexels-mcp-server to your MCP client code requirements.txt file.

    pexels-mcp-server
    
  2. Install the dependencies.

    pip install -r requirements.txt
    
  3. Add the configuration for your client:

    {
        "mcpServers": {
            "pexels": {
                "command": "python3",
                "args": ["-m", "pexels_mcp_server"],
                "env": {
                    "PEXELS_API_KEY": "<Your Pexels API key>"
                }
            }
        }
    }
    

Using pip globally

  1. Ensure pip or pip3 is available on your system.

    pip install pexels-mcp-server
    # or
    pip3 install pexels-mcp-server
    
  2. MCP client code configuration or Claude settings, add pexels mcp server:

    {
        "mcpServers": {
            "pexels": {
                "command": "python3",
                "args": ["pexels-mcp-server"],
                "env": {
                    "PEXELS_API_KEY": "<Your Pexels API key>"
                }
            }
        }
    }
    

Debugging

You can use the MCP inspector to debug the server. For uvx installations:

npx @modelcontextprotocol/inspector uvx pexels-mcp-server

Or if you've installed the package in a specific directory or are developing on it:

git clone https://github.com/garylab/pexels-mcp-server.git
cd pexels-mcp-server
npx @modelcontextprotocol/inspector uv run pexels-mcp-server -e PEXELS_API_KEY=<the key>

License

pexels-mcp-server is licensed under the MIT License. This means you are free to use, modify, and distribute the software, subject to the terms and conditions of the MIT License. For more details, please see the LICENSE file in the project repository.

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

pexels_mcp_server-0.0.4.tar.gz (47.8 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

pexels_mcp_server-0.0.4-py3-none-any.whl (6.2 kB view details)

Uploaded Python 3

File details

Details for the file pexels_mcp_server-0.0.4.tar.gz.

File metadata

  • Download URL: pexels_mcp_server-0.0.4.tar.gz
  • Upload date:
  • Size: 47.8 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: uv/0.8.17

File hashes

Hashes for pexels_mcp_server-0.0.4.tar.gz
Algorithm Hash digest
SHA256 8faf2b55484f8d0ed5b0be5d65ba87af308850d90af7a58b4459c081696a408d
MD5 c87f8223c3fceb62e34eb0d65655b57a
BLAKE2b-256 f6d6926d5af318ebd86908316cad3ead41dc8750e013679ab2f3585095fab61e

See more details on using hashes here.

File details

Details for the file pexels_mcp_server-0.0.4-py3-none-any.whl.

File metadata

File hashes

Hashes for pexels_mcp_server-0.0.4-py3-none-any.whl
Algorithm Hash digest
SHA256 15060e9ba3aaaef2fc25ce5b266de1a58f4fd6418ddd8f51b742f5bbef408d5d
MD5 aca12da9d3519cd1bf975c169d36bbee
BLAKE2b-256 3e8cd2a9fb1022a74208d23a099d35e480af0af3e30b79bc78bf6dde4b3d9d35

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page