1. Packages
  2. NS1
  3. API Docs
  4. Redirect
NS1 v3.3.0 published on Monday, Jun 24, 2024 by Pulumi

ns1.Redirect

Explore with Pulumi AI

ns1 logo
NS1 v3.3.0 published on Monday, Jun 24, 2024 by Pulumi

    Provides a NS1 Redirect resource. This can be used to create, modify, and delete redirects.

    Example Usage

    import * as pulumi from "@pulumi/pulumi";
    import * as ns1 from "@pulumi/ns1";
    
    const example = new ns1.Redirect("example", {
        domain: "www.example.com",
        path: "/from/path",
        target: "https://url.com/target/path",
    });
    
    import pulumi
    import pulumi_ns1 as ns1
    
    example = ns1.Redirect("example",
        domain="www.example.com",
        path="/from/path",
        target="https://url.com/target/path")
    
    package main
    
    import (
    	"github.com/pulumi/pulumi-ns1/sdk/v3/go/ns1"
    	"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
    )
    
    func main() {
    	pulumi.Run(func(ctx *pulumi.Context) error {
    		_, err := ns1.NewRedirect(ctx, "example", &ns1.RedirectArgs{
    			Domain: pulumi.String("www.example.com"),
    			Path:   pulumi.String("/from/path"),
    			Target: pulumi.String("https://url.com/target/path"),
    		})
    		if err != nil {
    			return err
    		}
    		return nil
    	})
    }
    
    using System.Collections.Generic;
    using System.Linq;
    using Pulumi;
    using Ns1 = Pulumi.Ns1;
    
    return await Deployment.RunAsync(() => 
    {
        var example = new Ns1.Redirect("example", new()
        {
            Domain = "www.example.com",
            Path = "/from/path",
            Target = "https://url.com/target/path",
        });
    
    });
    
    package generated_program;
    
    import com.pulumi.Context;
    import com.pulumi.Pulumi;
    import com.pulumi.core.Output;
    import com.pulumi.ns1.Redirect;
    import com.pulumi.ns1.RedirectArgs;
    import java.util.List;
    import java.util.ArrayList;
    import java.util.Map;
    import java.io.File;
    import java.nio.file.Files;
    import java.nio.file.Paths;
    
    public class App {
        public static void main(String[] args) {
            Pulumi.run(App::stack);
        }
    
        public static void stack(Context ctx) {
            var example = new Redirect("example", RedirectArgs.builder()
                .domain("www.example.com")
                .path("/from/path")
                .target("https://url.com/target/path")
                .build());
    
        }
    }
    
    resources:
      example:
        type: ns1:Redirect
        properties:
          domain: www.example.com
          path: /from/path
          target: https://url.com/target/path
    

    Additional Examples

    import * as pulumi from "@pulumi/pulumi";
    import * as ns1 from "@pulumi/ns1";
    
    const example = new ns1.RedirectCertificate("example", {domain: "www.example.com"});
    
    import pulumi
    import pulumi_ns1 as ns1
    
    example = ns1.RedirectCertificate("example", domain="www.example.com")
    
    package main
    
    import (
    	"github.com/pulumi/pulumi-ns1/sdk/v3/go/ns1"
    	"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
    )
    
    func main() {
    	pulumi.Run(func(ctx *pulumi.Context) error {
    		_, err := ns1.NewRedirectCertificate(ctx, "example", &ns1.RedirectCertificateArgs{
    			Domain: pulumi.String("www.example.com"),
    		})
    		if err != nil {
    			return err
    		}
    		return nil
    	})
    }
    
    using System.Collections.Generic;
    using System.Linq;
    using Pulumi;
    using Ns1 = Pulumi.Ns1;
    
    return await Deployment.RunAsync(() => 
    {
        var example = new Ns1.RedirectCertificate("example", new()
        {
            Domain = "www.example.com",
        });
    
    });
    
    package generated_program;
    
    import com.pulumi.Context;
    import com.pulumi.Pulumi;
    import com.pulumi.core.Output;
    import com.pulumi.ns1.RedirectCertificate;
    import com.pulumi.ns1.RedirectCertificateArgs;
    import java.util.List;
    import java.util.ArrayList;
    import java.util.Map;
    import java.io.File;
    import java.nio.file.Files;
    import java.nio.file.Paths;
    
    public class App {
        public static void main(String[] args) {
            Pulumi.run(App::stack);
        }
    
        public static void stack(Context ctx) {
            var example = new RedirectCertificate("example", RedirectCertificateArgs.builder()
                .domain("www.example.com")
                .build());
    
        }
    }
    
    resources:
      example:
        type: ns1:RedirectCertificate
        properties:
          domain: www.example.com
    

    NS1 Documentation

    Redirect Api Doc

    ns1_redirect_certificate

    Provides a NS1 Redirect Certificate resource. This can be used to create, modify, and delete redirect certificates.

    NS1 Documentation

    Redirect Api Doc

    Create Redirect Resource

    Resources are created with functions called constructors. To learn more about declaring and configuring resources, see Resources.

    Constructor syntax

    new Redirect(name: string, args: RedirectArgs, opts?: CustomResourceOptions);
    @overload
    def Redirect(resource_name: str,
                 args: RedirectArgs,
                 opts: Optional[ResourceOptions] = None)
    
    @overload
    def Redirect(resource_name: str,
                 opts: Optional[ResourceOptions] = None,
                 domain: Optional[str] = None,
                 path: Optional[str] = None,
                 target: Optional[str] = None,
                 certificate_id: Optional[str] = None,
                 forwarding_mode: Optional[str] = None,
                 forwarding_type: Optional[str] = None,
                 https_forced: Optional[bool] = None,
                 query_forwarding: Optional[bool] = None,
                 tags: Optional[Sequence[str]] = None)
    func NewRedirect(ctx *Context, name string, args RedirectArgs, opts ...ResourceOption) (*Redirect, error)
    public Redirect(string name, RedirectArgs args, CustomResourceOptions? opts = null)
    public Redirect(String name, RedirectArgs args)
    public Redirect(String name, RedirectArgs args, CustomResourceOptions options)
    
    type: ns1:Redirect
    properties: # The arguments to resource properties.
    options: # Bag of options to control resource's behavior.
    
    

    Parameters

    name string
    The unique name of the resource.
    args RedirectArgs
    The arguments to resource properties.
    opts CustomResourceOptions
    Bag of options to control resource's behavior.
    resource_name str
    The unique name of the resource.
    args RedirectArgs
    The arguments to resource properties.
    opts ResourceOptions
    Bag of options to control resource's behavior.
    ctx Context
    Context object for the current deployment.
    name string
    The unique name of the resource.
    args RedirectArgs
    The arguments to resource properties.
    opts ResourceOption
    Bag of options to control resource's behavior.
    name string
    The unique name of the resource.
    args RedirectArgs
    The arguments to resource properties.
    opts CustomResourceOptions
    Bag of options to control resource's behavior.
    name String
    The unique name of the resource.
    args RedirectArgs
    The arguments to resource properties.
    options CustomResourceOptions
    Bag of options to control resource's behavior.

    Constructor example

    The following reference example uses placeholder values for all input properties.

    var redirectResource = new Ns1.Redirect("redirectResource", new()
    {
        Domain = "string",
        Path = "string",
        Target = "string",
        CertificateId = "string",
        ForwardingMode = "string",
        ForwardingType = "string",
        HttpsForced = false,
        QueryForwarding = false,
        Tags = new[]
        {
            "string",
        },
    });
    
    example, err := ns1.NewRedirect(ctx, "redirectResource", &ns1.RedirectArgs{
    	Domain:          pulumi.String("string"),
    	Path:            pulumi.String("string"),
    	Target:          pulumi.String("string"),
    	CertificateId:   pulumi.String("string"),
    	ForwardingMode:  pulumi.String("string"),
    	ForwardingType:  pulumi.String("string"),
    	HttpsForced:     pulumi.Bool(false),
    	QueryForwarding: pulumi.Bool(false),
    	Tags: pulumi.StringArray{
    		pulumi.String("string"),
    	},
    })
    
    var redirectResource = new Redirect("redirectResource", RedirectArgs.builder()
        .domain("string")
        .path("string")
        .target("string")
        .certificateId("string")
        .forwardingMode("string")
        .forwardingType("string")
        .httpsForced(false)
        .queryForwarding(false)
        .tags("string")
        .build());
    
    redirect_resource = ns1.Redirect("redirectResource",
        domain="string",
        path="string",
        target="string",
        certificate_id="string",
        forwarding_mode="string",
        forwarding_type="string",
        https_forced=False,
        query_forwarding=False,
        tags=["string"])
    
    const redirectResource = new ns1.Redirect("redirectResource", {
        domain: "string",
        path: "string",
        target: "string",
        certificateId: "string",
        forwardingMode: "string",
        forwardingType: "string",
        httpsForced: false,
        queryForwarding: false,
        tags: ["string"],
    });
    
    type: ns1:Redirect
    properties:
        certificateId: string
        domain: string
        forwardingMode: string
        forwardingType: string
        httpsForced: false
        path: string
        queryForwarding: false
        tags:
            - string
        target: string
    

    Redirect Resource Properties

    To learn more about resource properties and how to use them, see Inputs and Outputs in the Architecture and Concepts docs.

    Inputs

    The Redirect resource accepts the following input properties:

    Domain string
    The domain the redirect refers to.
    Path string
    The path on the domain to redirect from.
    Target string
    The URL to redirect to.
    CertificateId string
    The certificate redirect id.
    ForwardingMode string
    How the target is interpreted:

    • all appends the entire incoming path to the target destination;
    • capture appends only the part of the incoming path corresponding to the wildcard (*);
    • none does not append any part of the incoming path.
    ForwardingType string
    How the redirect is executed:

    • permanent (HTTP 301) indicates to search engines that they should remove the old page from their database and replace it with the new target page (this is recommended for SEO);
    • temporary (HTTP 302) less common, indicates that search engines should keep the old domain or page indexed as the redirect is only temporary (while both pages might appear in the search results, a temporary redirect suggests to the search engine that it should prefer the new target page);
    • masking preserves the redirected domain in the browser's address bar (this lets users see the address they entered, even though the displayed content comes from a different web page).
    HttpsForced bool
    Forces redirect for users that try to visit HTTP domain to HTTPS instead.
    QueryForwarding bool
    Enables the query string of a URL to be applied directly to the new target URL.
    Tags List<string>
    Tags associated with the configuration.
    Domain string
    The domain the redirect refers to.
    Path string
    The path on the domain to redirect from.
    Target string
    The URL to redirect to.
    CertificateId string
    The certificate redirect id.
    ForwardingMode string
    How the target is interpreted:

    • all appends the entire incoming path to the target destination;
    • capture appends only the part of the incoming path corresponding to the wildcard (*);
    • none does not append any part of the incoming path.
    ForwardingType string
    How the redirect is executed:

    • permanent (HTTP 301) indicates to search engines that they should remove the old page from their database and replace it with the new target page (this is recommended for SEO);
    • temporary (HTTP 302) less common, indicates that search engines should keep the old domain or page indexed as the redirect is only temporary (while both pages might appear in the search results, a temporary redirect suggests to the search engine that it should prefer the new target page);
    • masking preserves the redirected domain in the browser's address bar (this lets users see the address they entered, even though the displayed content comes from a different web page).
    HttpsForced bool
    Forces redirect for users that try to visit HTTP domain to HTTPS instead.
    QueryForwarding bool
    Enables the query string of a URL to be applied directly to the new target URL.
    Tags []string
    Tags associated with the configuration.
    domain String
    The domain the redirect refers to.
    path String
    The path on the domain to redirect from.
    target String
    The URL to redirect to.
    certificateId String
    The certificate redirect id.
    forwardingMode String
    How the target is interpreted:

    • all appends the entire incoming path to the target destination;
    • capture appends only the part of the incoming path corresponding to the wildcard (*);
    • none does not append any part of the incoming path.
    forwardingType String
    How the redirect is executed:

    • permanent (HTTP 301) indicates to search engines that they should remove the old page from their database and replace it with the new target page (this is recommended for SEO);
    • temporary (HTTP 302) less common, indicates that search engines should keep the old domain or page indexed as the redirect is only temporary (while both pages might appear in the search results, a temporary redirect suggests to the search engine that it should prefer the new target page);
    • masking preserves the redirected domain in the browser's address bar (this lets users see the address they entered, even though the displayed content comes from a different web page).
    httpsForced Boolean
    Forces redirect for users that try to visit HTTP domain to HTTPS instead.
    queryForwarding Boolean
    Enables the query string of a URL to be applied directly to the new target URL.
    tags List<String>
    Tags associated with the configuration.
    domain string
    The domain the redirect refers to.
    path string
    The path on the domain to redirect from.
    target string
    The URL to redirect to.
    certificateId string
    The certificate redirect id.
    forwardingMode string
    How the target is interpreted:

    • all appends the entire incoming path to the target destination;
    • capture appends only the part of the incoming path corresponding to the wildcard (*);
    • none does not append any part of the incoming path.
    forwardingType string
    How the redirect is executed:

    • permanent (HTTP 301) indicates to search engines that they should remove the old page from their database and replace it with the new target page (this is recommended for SEO);
    • temporary (HTTP 302) less common, indicates that search engines should keep the old domain or page indexed as the redirect is only temporary (while both pages might appear in the search results, a temporary redirect suggests to the search engine that it should prefer the new target page);
    • masking preserves the redirected domain in the browser's address bar (this lets users see the address they entered, even though the displayed content comes from a different web page).
    httpsForced boolean
    Forces redirect for users that try to visit HTTP domain to HTTPS instead.
    queryForwarding boolean
    Enables the query string of a URL to be applied directly to the new target URL.
    tags string[]
    Tags associated with the configuration.
    domain str
    The domain the redirect refers to.
    path str
    The path on the domain to redirect from.
    target str
    The URL to redirect to.
    certificate_id str
    The certificate redirect id.
    forwarding_mode str
    How the target is interpreted:

    • all appends the entire incoming path to the target destination;
    • capture appends only the part of the incoming path corresponding to the wildcard (*);
    • none does not append any part of the incoming path.
    forwarding_type str
    How the redirect is executed:

    • permanent (HTTP 301) indicates to search engines that they should remove the old page from their database and replace it with the new target page (this is recommended for SEO);
    • temporary (HTTP 302) less common, indicates that search engines should keep the old domain or page indexed as the redirect is only temporary (while both pages might appear in the search results, a temporary redirect suggests to the search engine that it should prefer the new target page);
    • masking preserves the redirected domain in the browser's address bar (this lets users see the address they entered, even though the displayed content comes from a different web page).
    https_forced bool
    Forces redirect for users that try to visit HTTP domain to HTTPS instead.
    query_forwarding bool
    Enables the query string of a URL to be applied directly to the new target URL.
    tags Sequence[str]
    Tags associated with the configuration.
    domain String
    The domain the redirect refers to.
    path String
    The path on the domain to redirect from.
    target String
    The URL to redirect to.
    certificateId String
    The certificate redirect id.
    forwardingMode String
    How the target is interpreted:

    • all appends the entire incoming path to the target destination;
    • capture appends only the part of the incoming path corresponding to the wildcard (*);
    • none does not append any part of the incoming path.
    forwardingType String
    How the redirect is executed:

    • permanent (HTTP 301) indicates to search engines that they should remove the old page from their database and replace it with the new target page (this is recommended for SEO);
    • temporary (HTTP 302) less common, indicates that search engines should keep the old domain or page indexed as the redirect is only temporary (while both pages might appear in the search results, a temporary redirect suggests to the search engine that it should prefer the new target page);
    • masking preserves the redirected domain in the browser's address bar (this lets users see the address they entered, even though the displayed content comes from a different web page).
    httpsForced Boolean
    Forces redirect for users that try to visit HTTP domain to HTTPS instead.
    queryForwarding Boolean
    Enables the query string of a URL to be applied directly to the new target URL.
    tags List<String>
    Tags associated with the configuration.

    Outputs

    All input properties are implicitly available as output properties. Additionally, the Redirect resource produces the following output properties:

    HttpsEnabled bool
    True if HTTPS is supported on the source domain by using Let's Encrypt certificates.
    Id string
    The provider-assigned unique ID for this managed resource.
    LastUpdated int
    The Unix timestamp representing when the certificate was last signed.
    HttpsEnabled bool
    True if HTTPS is supported on the source domain by using Let's Encrypt certificates.
    Id string
    The provider-assigned unique ID for this managed resource.
    LastUpdated int
    The Unix timestamp representing when the certificate was last signed.
    httpsEnabled Boolean
    True if HTTPS is supported on the source domain by using Let's Encrypt certificates.
    id String
    The provider-assigned unique ID for this managed resource.
    lastUpdated Integer
    The Unix timestamp representing when the certificate was last signed.
    httpsEnabled boolean
    True if HTTPS is supported on the source domain by using Let's Encrypt certificates.
    id string
    The provider-assigned unique ID for this managed resource.
    lastUpdated number
    The Unix timestamp representing when the certificate was last signed.
    https_enabled bool
    True if HTTPS is supported on the source domain by using Let's Encrypt certificates.
    id str
    The provider-assigned unique ID for this managed resource.
    last_updated int
    The Unix timestamp representing when the certificate was last signed.
    httpsEnabled Boolean
    True if HTTPS is supported on the source domain by using Let's Encrypt certificates.
    id String
    The provider-assigned unique ID for this managed resource.
    lastUpdated Number
    The Unix timestamp representing when the certificate was last signed.

    Look up Existing Redirect Resource

    Get an existing Redirect resource’s state with the given name, ID, and optional extra properties used to qualify the lookup.

    public static get(name: string, id: Input<ID>, state?: RedirectState, opts?: CustomResourceOptions): Redirect
    @staticmethod
    def get(resource_name: str,
            id: str,
            opts: Optional[ResourceOptions] = None,
            certificate_id: Optional[str] = None,
            domain: Optional[str] = None,
            forwarding_mode: Optional[str] = None,
            forwarding_type: Optional[str] = None,
            https_enabled: Optional[bool] = None,
            https_forced: Optional[bool] = None,
            last_updated: Optional[int] = None,
            path: Optional[str] = None,
            query_forwarding: Optional[bool] = None,
            tags: Optional[Sequence[str]] = None,
            target: Optional[str] = None) -> Redirect
    func GetRedirect(ctx *Context, name string, id IDInput, state *RedirectState, opts ...ResourceOption) (*Redirect, error)
    public static Redirect Get(string name, Input<string> id, RedirectState? state, CustomResourceOptions? opts = null)
    public static Redirect get(String name, Output<String> id, RedirectState state, CustomResourceOptions options)
    Resource lookup is not supported in YAML
    name
    The unique name of the resulting resource.
    id
    The unique provider ID of the resource to lookup.
    state
    Any extra arguments used during the lookup.
    opts
    A bag of options that control this resource's behavior.
    resource_name
    The unique name of the resulting resource.
    id
    The unique provider ID of the resource to lookup.
    name
    The unique name of the resulting resource.
    id
    The unique provider ID of the resource to lookup.
    state
    Any extra arguments used during the lookup.
    opts
    A bag of options that control this resource's behavior.
    name
    The unique name of the resulting resource.
    id
    The unique provider ID of the resource to lookup.
    state
    Any extra arguments used during the lookup.
    opts
    A bag of options that control this resource's behavior.
    name
    The unique name of the resulting resource.
    id
    The unique provider ID of the resource to lookup.
    state
    Any extra arguments used during the lookup.
    opts
    A bag of options that control this resource's behavior.
    The following state arguments are supported:
    CertificateId string
    The certificate redirect id.
    Domain string
    The domain the redirect refers to.
    ForwardingMode string
    How the target is interpreted:

    • all appends the entire incoming path to the target destination;
    • capture appends only the part of the incoming path corresponding to the wildcard (*);
    • none does not append any part of the incoming path.
    ForwardingType string
    How the redirect is executed:

    • permanent (HTTP 301) indicates to search engines that they should remove the old page from their database and replace it with the new target page (this is recommended for SEO);
    • temporary (HTTP 302) less common, indicates that search engines should keep the old domain or page indexed as the redirect is only temporary (while both pages might appear in the search results, a temporary redirect suggests to the search engine that it should prefer the new target page);
    • masking preserves the redirected domain in the browser's address bar (this lets users see the address they entered, even though the displayed content comes from a different web page).
    HttpsEnabled bool
    True if HTTPS is supported on the source domain by using Let's Encrypt certificates.
    HttpsForced bool
    Forces redirect for users that try to visit HTTP domain to HTTPS instead.
    LastUpdated int
    The Unix timestamp representing when the certificate was last signed.
    Path string
    The path on the domain to redirect from.
    QueryForwarding bool
    Enables the query string of a URL to be applied directly to the new target URL.
    Tags List<string>
    Tags associated with the configuration.
    Target string
    The URL to redirect to.
    CertificateId string
    The certificate redirect id.
    Domain string
    The domain the redirect refers to.
    ForwardingMode string
    How the target is interpreted:

    • all appends the entire incoming path to the target destination;
    • capture appends only the part of the incoming path corresponding to the wildcard (*);
    • none does not append any part of the incoming path.
    ForwardingType string
    How the redirect is executed:

    • permanent (HTTP 301) indicates to search engines that they should remove the old page from their database and replace it with the new target page (this is recommended for SEO);
    • temporary (HTTP 302) less common, indicates that search engines should keep the old domain or page indexed as the redirect is only temporary (while both pages might appear in the search results, a temporary redirect suggests to the search engine that it should prefer the new target page);
    • masking preserves the redirected domain in the browser's address bar (this lets users see the address they entered, even though the displayed content comes from a different web page).
    HttpsEnabled bool
    True if HTTPS is supported on the source domain by using Let's Encrypt certificates.
    HttpsForced bool
    Forces redirect for users that try to visit HTTP domain to HTTPS instead.
    LastUpdated int
    The Unix timestamp representing when the certificate was last signed.
    Path string
    The path on the domain to redirect from.
    QueryForwarding bool
    Enables the query string of a URL to be applied directly to the new target URL.
    Tags []string
    Tags associated with the configuration.
    Target string
    The URL to redirect to.
    certificateId String
    The certificate redirect id.
    domain String
    The domain the redirect refers to.
    forwardingMode String
    How the target is interpreted:

    • all appends the entire incoming path to the target destination;
    • capture appends only the part of the incoming path corresponding to the wildcard (*);
    • none does not append any part of the incoming path.
    forwardingType String
    How the redirect is executed:

    • permanent (HTTP 301) indicates to search engines that they should remove the old page from their database and replace it with the new target page (this is recommended for SEO);
    • temporary (HTTP 302) less common, indicates that search engines should keep the old domain or page indexed as the redirect is only temporary (while both pages might appear in the search results, a temporary redirect suggests to the search engine that it should prefer the new target page);
    • masking preserves the redirected domain in the browser's address bar (this lets users see the address they entered, even though the displayed content comes from a different web page).
    httpsEnabled Boolean
    True if HTTPS is supported on the source domain by using Let's Encrypt certificates.
    httpsForced Boolean
    Forces redirect for users that try to visit HTTP domain to HTTPS instead.
    lastUpdated Integer
    The Unix timestamp representing when the certificate was last signed.
    path String
    The path on the domain to redirect from.
    queryForwarding Boolean
    Enables the query string of a URL to be applied directly to the new target URL.
    tags List<String>
    Tags associated with the configuration.
    target String
    The URL to redirect to.
    certificateId string
    The certificate redirect id.
    domain string
    The domain the redirect refers to.
    forwardingMode string
    How the target is interpreted:

    • all appends the entire incoming path to the target destination;
    • capture appends only the part of the incoming path corresponding to the wildcard (*);
    • none does not append any part of the incoming path.
    forwardingType string
    How the redirect is executed:

    • permanent (HTTP 301) indicates to search engines that they should remove the old page from their database and replace it with the new target page (this is recommended for SEO);
    • temporary (HTTP 302) less common, indicates that search engines should keep the old domain or page indexed as the redirect is only temporary (while both pages might appear in the search results, a temporary redirect suggests to the search engine that it should prefer the new target page);
    • masking preserves the redirected domain in the browser's address bar (this lets users see the address they entered, even though the displayed content comes from a different web page).
    httpsEnabled boolean
    True if HTTPS is supported on the source domain by using Let's Encrypt certificates.
    httpsForced boolean
    Forces redirect for users that try to visit HTTP domain to HTTPS instead.
    lastUpdated number
    The Unix timestamp representing when the certificate was last signed.
    path string
    The path on the domain to redirect from.
    queryForwarding boolean
    Enables the query string of a URL to be applied directly to the new target URL.
    tags string[]
    Tags associated with the configuration.
    target string
    The URL to redirect to.
    certificate_id str
    The certificate redirect id.
    domain str
    The domain the redirect refers to.
    forwarding_mode str
    How the target is interpreted:

    • all appends the entire incoming path to the target destination;
    • capture appends only the part of the incoming path corresponding to the wildcard (*);
    • none does not append any part of the incoming path.
    forwarding_type str
    How the redirect is executed:

    • permanent (HTTP 301) indicates to search engines that they should remove the old page from their database and replace it with the new target page (this is recommended for SEO);
    • temporary (HTTP 302) less common, indicates that search engines should keep the old domain or page indexed as the redirect is only temporary (while both pages might appear in the search results, a temporary redirect suggests to the search engine that it should prefer the new target page);
    • masking preserves the redirected domain in the browser's address bar (this lets users see the address they entered, even though the displayed content comes from a different web page).
    https_enabled bool
    True if HTTPS is supported on the source domain by using Let's Encrypt certificates.
    https_forced bool
    Forces redirect for users that try to visit HTTP domain to HTTPS instead.
    last_updated int
    The Unix timestamp representing when the certificate was last signed.
    path str
    The path on the domain to redirect from.
    query_forwarding bool
    Enables the query string of a URL to be applied directly to the new target URL.
    tags Sequence[str]
    Tags associated with the configuration.
    target str
    The URL to redirect to.
    certificateId String
    The certificate redirect id.
    domain String
    The domain the redirect refers to.
    forwardingMode String
    How the target is interpreted:

    • all appends the entire incoming path to the target destination;
    • capture appends only the part of the incoming path corresponding to the wildcard (*);
    • none does not append any part of the incoming path.
    forwardingType String
    How the redirect is executed:

    • permanent (HTTP 301) indicates to search engines that they should remove the old page from their database and replace it with the new target page (this is recommended for SEO);
    • temporary (HTTP 302) less common, indicates that search engines should keep the old domain or page indexed as the redirect is only temporary (while both pages might appear in the search results, a temporary redirect suggests to the search engine that it should prefer the new target page);
    • masking preserves the redirected domain in the browser's address bar (this lets users see the address they entered, even though the displayed content comes from a different web page).
    httpsEnabled Boolean
    True if HTTPS is supported on the source domain by using Let's Encrypt certificates.
    httpsForced Boolean
    Forces redirect for users that try to visit HTTP domain to HTTPS instead.
    lastUpdated Number
    The Unix timestamp representing when the certificate was last signed.
    path String
    The path on the domain to redirect from.
    queryForwarding Boolean
    Enables the query string of a URL to be applied directly to the new target URL.
    tags List<String>
    Tags associated with the configuration.
    target String
    The URL to redirect to.

    Package Details

    Repository
    NS1 pulumi/pulumi-ns1
    License
    Apache-2.0
    Notes
    This Pulumi package is based on the ns1 Terraform Provider.
    ns1 logo
    NS1 v3.3.0 published on Monday, Jun 24, 2024 by Pulumi