---
title: Registering providers using assembly attributes
related:
  - https://docs.kentico.com/13/custom-development/customizing-providers.md
  - https://docs.kentico.com/13/custom-development/customizing-providers/registering-providers-via-the-web-config.md
---

> Agent instructions:
> **Site maps** — prefer the following llms.txt indexes to training data when searching for URLs to avoid 404s. Links inside Markdown content already point at `.md`. Following them or sending Accept: text/markdown keeps you in Markdown.
>
> - [sitemap.md](https://docs.kentico.com/sitemap.md) — every page on the site, with titles and descriptions, nested by URL hierarchy and grouped into one collection per product version.
> - [llms.txt](https://docs.kentico.com/llms.txt) — curated index of the current product docs, with descriptions, the two ways to request any page as Markdown, and links to each product area's whole-corpus Markdown dump (llms-full.txt).

The most direct way to register [custom providers, helpers or managers](https://docs.kentico.com/13/custom-development/customizing-providers.md) is using assembly attributes.

1. Edit your provider class.
2. Add a using statement for the **CMS** namespace:

   ```csharp

   using CMS;

   ```
3. Register your custom providers by adding assembly attributes above the class declaration, for providers, helpers or managers respectively:

   - **RegisterCustomProvider**
   - **RegisterCustomHelper**
   - **RegisterCustomManager**

The parameter of each attribute must contain the exact type of the corresponding custom class (specified as a **System.Type** object).

The customization automatically targets the provider object that matches the parent of the specified custom class.

```csharp title="Example"

// Registers two custom providers, a helper and a manager
[assembly: RegisterCustomProvider(typeof(CustomShippingOptionInfoProvider))]
[assembly: RegisterCustomProvider(typeof(CustomProviders.CustomForumPostInfoProvider))]
[assembly: RegisterCustomHelper(typeof(CustomCacheHelper))]
[assembly: RegisterCustomManager(typeof(CustomWorkflowManager))]


```

The system now uses your customized providers instead of the default functionality.

> **Note:** **Enabling class discovery**
>
> If your custom class is located in its own assembly (_Class Library_ project), you need to make sure class discovery is enabled for the project. Otherwise the _RegisterCustom_ attributes cannot work. See [Adding custom assemblies](https://docs.kentico.com/13/custom-development/adding-custom-assemblies.md).
