Closes #57
This commit is contained in:
@ -179,6 +179,10 @@ def upload(**kwargs):
|
||||
kwargs.get('intermediate_cert'),
|
||||
)
|
||||
|
||||
# we override the generated name if one is provided
|
||||
if kwargs.get('name'):
|
||||
cert.name = kwargs['name']
|
||||
|
||||
cert.description = kwargs.get('description')
|
||||
|
||||
cert.owner = kwargs['owner']
|
||||
|
@ -332,7 +332,8 @@ class CertificatesUpload(AuthenticatedResource):
|
||||
"intermediateCert": "---Begin Public...",
|
||||
"privateKey": "---Begin Private..."
|
||||
"destinations": [],
|
||||
"notifications": []
|
||||
"notifications": [],
|
||||
"name": "cert1"
|
||||
}
|
||||
|
||||
**Example response**:
|
||||
@ -373,6 +374,7 @@ class CertificatesUpload(AuthenticatedResource):
|
||||
"""
|
||||
self.reqparse.add_argument('description', type=str, location='json')
|
||||
self.reqparse.add_argument('owner', type=str, required=True, location='json')
|
||||
self.reqparse.add_argument('name', type=str, location='json')
|
||||
self.reqparse.add_argument('publicCert', type=pem_str, required=True, dest='public_cert', location='json')
|
||||
self.reqparse.add_argument('destinations', type=list, default=[], dest='destinations', location='json')
|
||||
self.reqparse.add_argument('notifications', type=list, default=[], dest='notifications', location='json')
|
||||
|
Reference in New Issue
Block a user