你当前正在访问 Microsoft Azure Global Edition 技术文档网站。 如果需要访问由世纪互联运营的 Microsoft Azure 中国技术文档网站,请访问 https://docs.azure.cn。
Microsoft.ApiManagement 服务/portalconfigs 2021-12-01-preview
Bicep 资源定义
可以使用目标操作部署服务/门户配置资源类型:
- 资源组 - 请参阅 资源组部署命令
有关每个 API 版本中已更改属性的列表,请参阅 更改日志。
资源格式
若要创建 Microsoft.ApiManagement/service/portalconfigs 资源,请将以下 Bicep 添加到模板。
resource symbolicname 'Microsoft.ApiManagement/service/portalconfigs@2021-12-01-preview' = {
parent: resourceSymbolicName
name: 'string'
properties: {
cors: {
allowedOrigins: [
'string'
]
}
csp: {
allowedSources: [
'string'
]
mode: 'string'
reportUri: [
'string'
]
}
delegation: {
delegateRegistration: bool
delegateSubscription: bool
delegationUrl: 'string'
validationKey: 'string'
}
enableBasicAuth: bool
signin: {
require: bool
}
signup: {
termsOfService: {
requireConsent: bool
text: 'string'
}
}
}
}
属性值
Microsoft.ApiManagement/service/portalconfigs
名字 | 描述 | 价值 |
---|---|---|
名字 | 资源名称 | 字符串 约束: 最小长度 = 1 最大长度 = 80 (必需) |
父母 | 在 Bicep 中,可以为子资源指定父资源。 仅当子资源在父资源外部声明时,才需要添加此属性。 有关详细信息,请参阅 父资源外部的子资源。 |
类型资源的符号名称:服务 |
性能 | 开发人员门户配置协定属性。 | PortalConfigProperties |
PortalConfigCorsProperties
名字 | 描述 | 价值 |
---|---|---|
allowedOrigins | 允许的源,例如 https://trusted.com 。 |
string[] |
PortalConfigCspProperties
名字 | 描述 | 价值 |
---|---|---|
allowedSources | 允许的源,例如 *.trusted.com 、trusted.com 、https:// 。 |
string[] |
模式 | 开发人员门户内容安全策略(CSP)的模式。 | “disabled” “enabled” “reportOnly” |
reportUri | 浏览器用于报告 CSP 冲突的 URL。 | string[] |
PortalConfigDelegationProperties
名字 | 描述 | 价值 |
---|---|---|
delegateRegistration | 启用或禁用用户注册的委派。 | bool |
delegateSubscription | 启用或禁用产品订阅的委派。 | bool |
delegationUrl | 委派终结点 URL。 | 字符串 |
validationKey | base64 编码的验证密钥,以确保请求源自 Azure API 管理服务。 | 字符串 约束: 敏感值。 以安全参数的形式传入。 |
PortalConfigProperties
名字 | 描述 | 价值 |
---|---|---|
cors | 开发人员门户跨域资源共享(CORS)设置。 | PortalConfigCorsProperties |
csp | 开发人员门户内容安全策略 (CSP) 设置。 | PortalConfigCspProperties |
代表团 | 开发人员门户委派设置。 | PortalConfigDelegationProperties |
enableBasicAuth | 启用或禁用基本身份验证方法。 | bool |
signin | PortalConfigPropertiesSignin | |
注册 | PortalConfigPropertiesSignup |
PortalConfigPropertiesSignin
名字 | 描述 | 价值 |
---|---|---|
需要 | 将匿名用户重定向到登录页。 | bool |
PortalConfigPropertiesSignup
名字 | 描述 | 价值 |
---|---|---|
termsOfService | 服务条款设置。 | PortalConfigTermsOfServiceProperties |
PortalConfigTermsOfServiceProperties
名字 | 描述 | 价值 |
---|---|---|
requireConsent | 要求用户同意服务条款。 | bool |
发短信 | 服务条款文本。 | 字符串 |
ARM 模板资源定义
可以使用目标操作部署服务/门户配置资源类型:
- 资源组 - 请参阅 资源组部署命令
有关每个 API 版本中已更改属性的列表,请参阅 更改日志。
资源格式
若要创建 Microsoft.ApiManagement/service/portalconfigs 资源,请将以下 JSON 添加到模板。
{
"type": "Microsoft.ApiManagement/service/portalconfigs",
"apiVersion": "2021-12-01-preview",
"name": "string",
"properties": {
"cors": {
"allowedOrigins": [ "string" ]
},
"csp": {
"allowedSources": [ "string" ],
"mode": "string",
"reportUri": [ "string" ]
},
"delegation": {
"delegateRegistration": "bool",
"delegateSubscription": "bool",
"delegationUrl": "string",
"validationKey": "string"
},
"enableBasicAuth": "bool",
"signin": {
"require": "bool"
},
"signup": {
"termsOfService": {
"requireConsent": "bool",
"text": "string"
}
}
}
}
属性值
Microsoft.ApiManagement/service/portalconfigs
名字 | 描述 | 价值 |
---|---|---|
apiVersion | API 版本 | '2021-12-01-preview' |
名字 | 资源名称 | 字符串 约束: 最小长度 = 1 最大长度 = 80 (必需) |
性能 | 开发人员门户配置协定属性。 | PortalConfigProperties |
类型 | 资源类型 | “Microsoft.ApiManagement/service/portalconfigs” |
PortalConfigCorsProperties
名字 | 描述 | 价值 |
---|---|---|
allowedOrigins | 允许的源,例如 https://trusted.com 。 |
string[] |
PortalConfigCspProperties
名字 | 描述 | 价值 |
---|---|---|
allowedSources | 允许的源,例如 *.trusted.com 、trusted.com 、https:// 。 |
string[] |
模式 | 开发人员门户内容安全策略(CSP)的模式。 | “disabled” “enabled” “reportOnly” |
reportUri | 浏览器用于报告 CSP 冲突的 URL。 | string[] |
PortalConfigDelegationProperties
名字 | 描述 | 价值 |
---|---|---|
delegateRegistration | 启用或禁用用户注册的委派。 | bool |
delegateSubscription | 启用或禁用产品订阅的委派。 | bool |
delegationUrl | 委派终结点 URL。 | 字符串 |
validationKey | base64 编码的验证密钥,以确保请求源自 Azure API 管理服务。 | 字符串 约束: 敏感值。 以安全参数的形式传入。 |
PortalConfigProperties
名字 | 描述 | 价值 |
---|---|---|
cors | 开发人员门户跨域资源共享(CORS)设置。 | PortalConfigCorsProperties |
csp | 开发人员门户内容安全策略 (CSP) 设置。 | PortalConfigCspProperties |
代表团 | 开发人员门户委派设置。 | PortalConfigDelegationProperties |
enableBasicAuth | 启用或禁用基本身份验证方法。 | bool |
signin | PortalConfigPropertiesSignin | |
注册 | PortalConfigPropertiesSignup |
PortalConfigPropertiesSignin
名字 | 描述 | 价值 |
---|---|---|
需要 | 将匿名用户重定向到登录页。 | bool |
PortalConfigPropertiesSignup
名字 | 描述 | 价值 |
---|---|---|
termsOfService | 服务条款设置。 | PortalConfigTermsOfServiceProperties |
PortalConfigTermsOfServiceProperties
名字 | 描述 | 价值 |
---|---|---|
requireConsent | 要求用户同意服务条款。 | bool |
发短信 | 服务条款文本。 | 字符串 |
Terraform (AzAPI 提供程序)资源定义
可以使用目标操作部署服务/门户配置资源类型:
- 资源组
有关每个 API 版本中已更改属性的列表,请参阅 更改日志。
资源格式
若要创建 Microsoft.ApiManagement/service/portalconfigs 资源,请将以下 Terraform 添加到模板。
resource "azapi_resource" "symbolicname" {
type = "Microsoft.ApiManagement/service/portalconfigs@2021-12-01-preview"
name = "string"
body = jsonencode({
properties = {
cors = {
allowedOrigins = [
"string"
]
}
csp = {
allowedSources = [
"string"
]
mode = "string"
reportUri = [
"string"
]
}
delegation = {
delegateRegistration = bool
delegateSubscription = bool
delegationUrl = "string"
validationKey = "string"
}
enableBasicAuth = bool
signin = {
require = bool
}
signup = {
termsOfService = {
requireConsent = bool
text = "string"
}
}
}
})
}
属性值
Microsoft.ApiManagement/service/portalconfigs
名字 | 描述 | 价值 |
---|---|---|
名字 | 资源名称 | 字符串 约束: 最小长度 = 1 最大长度 = 80 (必需) |
parent_id | 此资源的父资源的 ID。 | 类型资源的 ID:服务 |
性能 | 开发人员门户配置协定属性。 | PortalConfigProperties |
类型 | 资源类型 | “Microsoft.ApiManagement/service/portalconfigs@2021-12-01-preview” |
PortalConfigCorsProperties
名字 | 描述 | 价值 |
---|---|---|
allowedOrigins | 允许的源,例如 https://trusted.com 。 |
string[] |
PortalConfigCspProperties
名字 | 描述 | 价值 |
---|---|---|
allowedSources | 允许的源,例如 *.trusted.com 、trusted.com 、https:// 。 |
string[] |
模式 | 开发人员门户内容安全策略(CSP)的模式。 | “disabled” “enabled” “reportOnly” |
reportUri | 浏览器用于报告 CSP 冲突的 URL。 | string[] |
PortalConfigDelegationProperties
名字 | 描述 | 价值 |
---|---|---|
delegateRegistration | 启用或禁用用户注册的委派。 | bool |
delegateSubscription | 启用或禁用产品订阅的委派。 | bool |
delegationUrl | 委派终结点 URL。 | 字符串 |
validationKey | base64 编码的验证密钥,以确保请求源自 Azure API 管理服务。 | 字符串 约束: 敏感值。 以安全参数的形式传入。 |
PortalConfigProperties
名字 | 描述 | 价值 |
---|---|---|
cors | 开发人员门户跨域资源共享(CORS)设置。 | PortalConfigCorsProperties |
csp | 开发人员门户内容安全策略 (CSP) 设置。 | PortalConfigCspProperties |
代表团 | 开发人员门户委派设置。 | PortalConfigDelegationProperties |
enableBasicAuth | 启用或禁用基本身份验证方法。 | bool |
signin | PortalConfigPropertiesSignin | |
注册 | PortalConfigPropertiesSignup |
PortalConfigPropertiesSignin
名字 | 描述 | 价值 |
---|---|---|
需要 | 将匿名用户重定向到登录页。 | bool |
PortalConfigPropertiesSignup
名字 | 描述 | 价值 |
---|---|---|
termsOfService | 服务条款设置。 | PortalConfigTermsOfServiceProperties |
PortalConfigTermsOfServiceProperties
名字 | 描述 | 价值 |
---|---|---|
requireConsent | 要求用户同意服务条款。 | bool |
发短信 | 服务条款文本。 | 字符串 |