November 23, 2017


Delete an origin mappings in a CDN.

Important manual pages:

Author: SoftLayer Technologies, Inc. <>
package main

import (

func main() {
	// SoftLayer API username and key
	username := "set me"
	apikey   := "set me"

	// The id of CDN Account you wish to delete an origin mapping
	cdnId := 8166

	// The id of origin pull mapping you wish to delete
	originId := "op1689589"

	// Create SoftLayer API session
	sess := session.New(username, apikey)

	// Get SoftLayer_Network_ContentDelivery_Account service
	service := services.GetNetworkContentDeliveryAccountService(sess)

	// Call the deleteOriginPullRule() method to delete the origin mapping
	result, err := service.Id(cdnId).DeleteOriginPullRule(sl.String(originId))
	if err != nil {
		fmt.Printf("\n Unable to delete origin pull mapping from CDN:\n - %s\n", err)



If this article contains any error, or leaves any of your questions unanswered, please help us out by opening up a github issue.
Open an issue