Search Results for

    Show / Hide Table of Contents
    View Source

    Class ApiDocumentUrlService

    Default implementation of IApiDocumentUrlService that retrieves document information by URL route.

    Inheritance
    object
    Namespace: Umbraco.Cms.Core.DeliveryApi
    Assembly: Umbraco.Core.dll
    Syntax
    public sealed class ApiDocumentUrlService : IApiDocumentUrlService

    Constructors

    View Source

    ApiDocumentUrlService(IDocumentUrlService)

    Initializes a new instance of the ApiDocumentUrlService class.

    Declaration
    public ApiDocumentUrlService(IDocumentUrlService documentUrlService)
    Parameters
    Type Name Description
    IDocumentUrlService documentUrlService

    The document URL service.

    Methods

    View Source

    GetDocumentKeyByRoute(string, string?, bool)

    Gets the document key (unique identifier) for the specified route.

    Declaration
    public Guid? GetDocumentKeyByRoute(string route, string? culture, bool preview)
    Parameters
    Type Name Description
    string route

    The URL route to look up.

    string culture

    The culture to use for the lookup, or null for the default culture.

    bool preview

    Whether to include unpublished preview content in the lookup.

    Returns
    Type Description
    Guid?

    The document key if found, or null if no document exists at the specified route.

    • View Source
    In this article
    Back to top Copyright © 2016-present Umbraco
    Generated by DocFX