融合 CDN

  • 证书相关

    最近更新时间:2018-12-10 16:30:25

    上传证书

    用户上传证书的接口, 注意我们不会自动补全证书链,需要用户自己补全
    
    

    请求包

    POST /sslcert
    
    {
        Cert
    }
    
    

    参数解释

    参数 类型 必填 含义
    Cert object 结构请参考 证书

    返回包

    {
        "certID": <CertID>
    }
    
    

    参数解释

    参数 类型 含义
    CertID string

    错误码

    错误码 含义
    400500 超过用户绑定证书最大额度
    404906 https证书解码失败
    400323 验证https证书链失败
    400322 https证书有效期太短
    400329 https证书过期

    请求示例

    POST /sslcert HTTP/1.1
    Authorization: QBox 0tf5awMVxwf8WrEvrjtbiZrdRZRJU-91JgCqTOC8:6oxDOtOXVEfcR8PPuAscmWjVRS8=
    Content-Type: application/json
    Host: api.qiniu.com
    
    {
      "name": "test.qbox.net",
      "common_name": "test.qbox.net",
      "ca": "-----BEGIN CERTIFICATE-----\nMIIE4zCCA8ugAwIGDgIQS8bzWqULBRrgekETXZfAuTANBgkqhkiG9w0BAQsFADBP\nMQswCQYDVQQGEwJDTjEaMBgGA1UEChMRV29TaWduIENBIExpbWl0ZWQxJDAiBgNV\nBAMMG0NBIOayg+mAmuWFjei0uVNTTOivgeS5piBHMjAeFw0xNjA2MTYwNzMyMzda\nFw0xODA2MTYwNzMyMzdaMBkxFzAVBgNVBAMMDmZ1emh1LnFib3gubmV0MIIBIjAN\nBgkqhkiG9w0BAQEFBBOCAQ8AMIIBCgKCAQEAlJJM7hokv++N8zRgPS48BMYR2RmS\nUGLAepVcO3Lr85Q7UnXpUa6vJeg6O6X0oEL410tOn4GnGzXnAbhKezx6tyihQV1x\nE+AxEVZh7G74G+uoXk6whauhepx51I6/HFO+THQVel0tNXjFnk7IpmvsrlhmjvLY\nLK6uXpPuUFemPf42IyM2e76zQg9TriBffg7z5Th1DvSnflJwu0utW5cUfkLnMU2d\nXCt2b446rp1JTbQcQL0GGrJWTXA9Gaemd6weQ1KZWROw7uvWBiS68GdflNBB1fRn\nWefXV6MKM+fhIdBJA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oSOA/AbaG6O0JdjdNqidbT8sFrONZhud/35X0Mas2m0qqW\n8OaC+SNkhDqQftFidU1tL4RatoicSbwjhDbEq18YyeHtOPGpUaWnsN+t4tO7q++Q\nqEvNy4txignrEhdg+fv1SQKBgB+Ex1lqhvMylyHUcRFwTEHykoOCyHDpXUVz2Pr4\ntABALaAhjSrHNvR831fL9AFDuwQ80kj5mVH+EgdwWbV17RG74Epmv6bRmSAPu1Lg\nZaUif1TXnRaCWudONVN0D8Ad3J6hkiScf5/BGddLBHoc671yUawcbwu0ylASd6Lh\nADnpAoGBAM40gO2n4N6g+BckdZaTTZYlzecVx4PHiZWM/vBtw603NAPczLC06jEJ\nRwaaOZvbApA+omyIDcVttTTwUmdd1BNnasslE2gmHJWRXZA/RjgMXoOwB6G1Jlk3\n9JF4ljvEeeRoKmuDJRsSn9w51y/ZtxUcfIypWa1hPjRSsDe8sXqV\n-----END RSA PRIVATE KEY-----"
    }
    

    删除证书

    用户删除证书的接口
    
    

    请求包

    DELETE /sslcert/<CertID>
    Authorization: QBox <AccessToken>
    
    

    参数解释

    参数 类型 含义
    CertID string

    返回包

    {}
    
    

    错误码

    错误码 含义
    400401 无此证书
    404908 无权操作该证书
    400611 证书已绑定域名

    获取证书

    用户获取单个证书的接口
    
    

    请求包

    GET /sslcert/<CertID>
    Authorization: QBox <AccessToken>
    
    

    参数解释

    参数 类型 含义
    CertID string

    返回包

    {
        Cert
    }
    
    

    参数解释

    参数 类型 含义
    Cert object 结构请参考 证书

    错误码

    错误码 含义
    400401 无此证书
    404908 无权操作该证书

    获取证书列表

    用户获取证书列表的接口
    
    

    请求包

    GET /sslcert?marker=<Marker>&limit=<Limit>
    Authorization: QBox <AccessToken>
    
    

    参数解释

    参数 类型 含义
    Marker string 用于标示从哪个位置开始获取证书列表。不填或空表示从头开始
    Limit int 返回的最大域名个数。默认 100

    返回包

    {
        "marker": <Marker>,
        "certs": [
            <Cert>,
            ...
        ]
    }
    
    

    参数解释

    参数 类型 含义
    Marker string 用于标示下一次从哪个位置开始获取证书列表
    Cert object 结构请参考 证书

    错误码

    错误码 含义
    404908 无权操作该证书
    以上内容是否对您有帮助?
  • Icon free helper
    Close