Skip to content

Repository files navigation

notion

Built with APIMatic License: MIT

The notion SDK for .NET provides access to the notion REST APIs from .NET applications.

The Notion API allows developers to integrate with Notion workspaces programmatically. Build integrations that connect Notion with other tools, automate workflows, and manage workspace content including pages, databases, blocks, users, comments, and search. Notion is an all-in-one workspace that combines notes, tasks, wikis, and databases into a flexible, collaborative platform.


Installation

Add the .NET SDK as a project reference into your solution:

dotnet add reference <path-to-sdk>/Notion.csproj

Quick Start

Dependency Injection

Register the client with IServiceCollection and resolve it from the container. The HttpClient is managed by IHttpClientFactory. Configure the client's behavior through NotionClientOptions.

services.AddNotionClient(options =>
    {
        options.BearerAuth = "YOUR_BEARER_TOKEN";
        options.Environment = ServerEnvironment.Production;
        // TODO: configure more client options here
    });

Direct Instantiation

Create the client by passing an HttpClient you manage yourself. Configure the client's behavior through NotionClientOptions.

var httpClient = new HttpClient();
// TODO: configure more client options here
var options =
    new NotionClientOptions
    {
        BearerAuth = "YOUR_BEARER_TOKEN",
        Environment = ServerEnvironment.Production,
    };
var client = new NotionClient(httpClient, options);

Usage

For code examples and error responses, see API Reference.

Best Practices

Tip

Use a single NotionClient instance for the lifetime of your application and reuse it across all requests. Creating a new instance per request might exhaust the connection pool.

License

This SDK is distributed under the MIT License.


Support

Refer to the API reference for detailed information on available operations with code samples.

For further assistance, please contact support at developers@makenotion.com.


About

csharp SDK for Notion

Resources

Stars

0 stars

Watchers

0 watching

Forks

Releases

Packages

Contributors

Languages