
Update the AMS channels that are configured with this key store certificate - go
Update the AMS channels that are configured with this key store certificate.
(mqcloud *MqcloudV1) SetCertificateAmsChannels(setCertificateAmsChannelsOptions *SetCertificateAmsChannelsOptions) (result *ChannelsDetails, response *core.DetailedResponse, err error)
(mqcloud *MqcloudV1) SetCertificateAmsChannelsWithContext(ctx context.Context, setCertificateAmsChannelsOptions *SetCertificateAmsChannelsOptions) (result *ChannelsDetails, response *core.DetailedResponse, err error)
Request
Instantiate the SetCertificateAmsChannelsOptions struct and set the fields to
provide parameter values for the SetCertificateAmsChannels method.
| parameter | WithContext method only |
|---|---|
ctxContext
|
A context.Context instance that you can use to specify a timeout for the operation or to cancel an in-flight request. |
| GetKeyStoreCertificateOptions | The GetKeyStoreCertificate options |
|---|---|
ServiceInstanceGuidRequired*
string |
The GUID that uniquely identifies the IBM® MQ as a Service instance. Possible values: length = 36, Value must match regular expression
Example: |
QueueManagerIDRequired*
string |
The id of the queue manager to retrieve its full details. Possible values:
length = 32, Value must match regular expression
b8e1aeda078009cf3db74e90d5d42328 |
CertificateFileRequired*
io.ReadCloser |
The filename and path of the certificate to be uploaded. Possible values: 1500 ≤ length ≤ 65537 Examples:[B@36ab3814 |
ChannelsAlways included*
|
A list of channels that use this certificate. Possible values: 0 ≤ number of items ≤ 999999999 |
|
|
UpdateStrategystring
|
Strategy for how the supplied channels should be applied. Allowable values:
[ |
Example request
channelDetailsModel := &mqcloudv1.ChannelDetails{
}
setCertificateAmsChannelsOptions := mqcloudService.NewSetCertificateAmsChannelsOptions(
"b8e1aeda078009cf3db74e90d5d42328",
"9b7d1e723af8233",
"a2b4d4bc-dadb-4637-bcec-9b7d1e723af8",
[]mqcloudv1.ChannelDetails{*channelDetailsModel},
)
channelsDetails, response, err := mqcloudService.SetCertificateAmsChannels(setCertificateAmsChannelsOptions)
if err != nil {
panic(err)
}
b, _ := json.MarshalIndent(channelsDetails, "", " ")
fmt.Println(string(b))
Response
| Response Body ChannelsDetails
|
A list of channels that are configured with this certificate. |
|---|---|
ChannelsAlways included*
|
A list of channels that are configured with this certificate. Possible values: 0 ≤ number of items ≤ 999999999 |
|
| Status code | |
|---|---|
| 200 | Details of AMS channels that are configured with the given certificate |
| 301 | URI has permanently Moved |
| 400 | Bad Request |
| 401 | Unauthorized |
| 404 | Resource not found |
| 429 | Service Is Overused |
| 500 | Internal Server Error |
Example response
Success example
{
"channels": [
{
"name": "CLOUD.APP.SVRCONN"
}
]
}