Skip to main content

URL

URL 是一种数据类型,被用于来保存网站链接。

💡 常用网址 Usage

例如,URL 属性类型可被用来存储指向任何网络资源的链接:

  • 链接到 Datadog 仪表板
  • 指向 Sentry 跟踪的链接
  • 链接到拉取请求

应用程序接口定义

{
"myUrlProp": {
"title": "My url",
"icon": "My icon",
"description": "My url property",
"type": "string",
"format": "url",
"default": "https://example.com"
}
}

Check out Port's API reference to learn more.

Terraform 定义

resource "port_blueprint" "myBlueprint" {
# ...blueprint properties
properties = {
string_props = {
"myUrlProp" = {
title = "My url"
required = false
format = "url"
}
}
}
}

Pulumi 的定义

"""A Python Pulumi program"""

import pulumi
from port_pulumi import Blueprint,BlueprintPropertiesArgs,BlueprintPropertiesStringPropsArgs

blueprint = Blueprint(
"myBlueprint",
identifier="myBlueprint",
title="My Blueprint",
properties=BlueprintPropertiesArgs(
string_props={
"myUrlProp": BlueprintPropertiesStringPropsArgs(
title="My url", required=False, format="url"
),
}
),
relations={}
)