

def add_origin(self, account_id, media_type, origin_url, cname=None, secure=False):
    "Adds an original pull mapping to an origin-pull.\n\n        :param int account_id: the numeric ID associated with the CDN account.\n        :param string media_type: the media type/protocol associated with this\n                                  origin pull mapping; valid values are HTTP,\n                                  FLASH, and WM.\n        :param string origin_url: the base URL from which content should be\n                                  pulled.\n        :param string cname: an optional CNAME that should be associated with\n                             this origin pull rule; only the hostname should be\n                             included (i.e., no 'http://', directories, etc.).\n        :param boolean secure: specifies whether this is an SSL origin pull\n                               rule, if SSL is enabled on your account\n                               (defaults to false).\n        "
    config = {
        'mediaType': media_type,
        'originUrl': origin_url,
        'isSecureContent': secure,
    }
    if cname:
        config['cname'] = cname
    return self.account.createOriginPullMapping(config, id=account_id)

dataset/ETHPy150Open softlayer/softlayer-python/SoftLayer/managers/cdn.py CDNManager.add_origin/original