diff --git a/acceptance/openstack/networking/v2/network_test.go b/acceptance/openstack/networking/v2/network_test.go
index b1d02b5..209a68c 100644
--- a/acceptance/openstack/networking/v2/network_test.go
+++ b/acceptance/openstack/networking/v2/network_test.go
@@ -44,6 +44,12 @@
 	Client = nil
 }
 
+func Equals(t *testing.T, actual interface{}, expected interface{}) {
+	if expected != actual {
+		t.Fatalf("Expected %#v but got %#v", expected, actual)
+	}
+}
+
 func TestListAPIVersions(t *testing.T) {
 	Setup(t)
 	defer Teardown()
@@ -91,7 +97,19 @@
 }
 
 func TestGetExt(t *testing.T) {
-	//networks.Extension()
+	Setup(t)
+	defer Teardown()
+
+	ext, err := networks.GetExtension(Client, "service-type")
+	if err != nil {
+		t.Fatalf("Unexpected error when getting extension: %#v", err)
+	}
+
+	Equals(t, ext.Updated, "2013-01-20T00:00:00-00:00")
+	Equals(t, ext.Name, "Neutron Service Type Management")
+	Equals(t, ext.Namespace, "http://docs.openstack.org/ext/neutron/service-type/api/v1.0")
+	Equals(t, ext.Alias, "service-type")
+	Equals(t, ext.Description, "API for retrieving service providers for Neutron advanced services")
 }
 
 func TestListNetworks(t *testing.T) {
diff --git a/openstack/networking/v2/networks/requests.go b/openstack/networking/v2/networks/requests.go
index 21055a8..cc57540 100644
--- a/openstack/networking/v2/networks/requests.go
+++ b/openstack/networking/v2/networks/requests.go
@@ -48,3 +48,19 @@
 
 	return &resp, nil
 }
+
+func GetExtension(c *gophercloud.ServiceClient, name string) (*Extension, error) {
+	var ext Extension
+	_, err := perigee.Request("GET", ExtensionURL(c, name), perigee.Options{
+		MoreHeaders: c.Provider.AuthenticatedHeaders(),
+		Results: &struct {
+			Extension *Extension `json:"extension"`
+		}{&ext},
+		OkCodes: []int{200},
+	})
+
+	if err != nil {
+		return nil, err
+	}
+	return &ext, nil
+}
diff --git a/openstack/networking/v2/networks/requests_test.go b/openstack/networking/v2/networks/requests_test.go
index 4d4bfe1..85e3ce0 100644
--- a/openstack/networking/v2/networks/requests_test.go
+++ b/openstack/networking/v2/networks/requests_test.go
@@ -21,6 +21,18 @@
 	}
 }
 
+func Equals(t *testing.T, actual interface{}, expected interface{}) {
+	if expected != actual {
+		t.Fatalf("Expected %#v but got %#v", expected, actual)
+	}
+}
+
+func CheckErr(t *testing.T, e error) {
+	if e != nil {
+		t.Fatalf("An error occurred: %#v", e)
+	}
+}
+
 func TestListAPIVersions(t *testing.T) {
 	th.SetupHTTP()
 	defer th.TeardownHTTP()
@@ -151,3 +163,44 @@
 		t.Errorf("Expected %#v, got %#v", expected, actual)
 	}
 }
+
+func TestListingExtensions(t *testing.T) {
+
+}
+
+func TestGettingExtension(t *testing.T) {
+	th.SetupHTTP()
+	defer th.TeardownHTTP()
+
+	th.Mux.HandleFunc("/v2.0/extension/agent", func(w http.ResponseWriter, r *http.Request) {
+		th.TestMethod(t, r, "GET")
+		th.TestHeader(t, r, "X-Auth-Token", TokenID)
+
+		w.Header().Add("Content-Type", "application/json")
+		w.WriteHeader(http.StatusOK)
+
+		fmt.Fprintf(w, `
+{
+    "extension": {
+        "updated": "2013-02-03T10:00:00-00:00",
+        "name": "agent",
+        "links": [],
+        "namespace": "http://docs.openstack.org/ext/agent/api/v2.0",
+        "alias": "agent",
+        "description": "The agent management extension."
+    }
+}
+		`)
+
+		c := ServiceClient()
+
+		ext, err := GetExtension(c, "agent")
+		CheckErr(t, err)
+
+		Equals(t, ext.Updated, "2013-02-03T10:00:00-00:00")
+		Equals(t, ext.Name, "agent")
+		Equals(t, ext.Namespace, "http://docs.openstack.org/ext/agent/api/v2.0")
+		Equals(t, ext.Alias, "agent")
+		Equals(t, ext.Description, "The agent management extension.")
+	})
+}
diff --git a/openstack/networking/v2/networks/results.go b/openstack/networking/v2/networks/results.go
index e601c57..61d51b0 100644
--- a/openstack/networking/v2/networks/results.go
+++ b/openstack/networking/v2/networks/results.go
@@ -128,3 +128,12 @@
 func ToAPIResource(results gophercloud.Collection) []APIResource {
 	return results.(*APIInfoList).APIResources
 }
+
+type Extension struct {
+	Updated     string        `json:"updated"`
+	Name        string        `json:"name"`
+	Links       []interface{} `json:"links"`
+	Namespace   string        `json:"namespace"`
+	Alias       string        `json:"alias"`
+	Description string        `json:"description"`
+}
diff --git a/openstack/networking/v2/networks/urls.go b/openstack/networking/v2/networks/urls.go
index 3f49261..8d350b1 100644
--- a/openstack/networking/v2/networks/urls.go
+++ b/openstack/networking/v2/networks/urls.go
@@ -6,6 +6,8 @@
 	"github.com/rackspace/gophercloud"
 )
 
+const Version = "v2.0"
+
 func APIVersionsURL(c *gophercloud.ServiceClient) string {
 	return c.ServiceURL("")
 }
@@ -13,3 +15,7 @@
 func APIInfoURL(c *gophercloud.ServiceClient, version string) string {
 	return c.ServiceURL(strings.TrimRight(version, "/") + "/")
 }
+
+func ExtensionURL(c *gophercloud.ServiceClient, name string) string {
+	return c.ServiceURL(Version, "extensions", name)
+}
diff --git a/openstack/networking/v2/networks/urls_test.go b/openstack/networking/v2/networks/urls_test.go
index a6c57e2..34009ed 100644
--- a/openstack/networking/v2/networks/urls_test.go
+++ b/openstack/networking/v2/networks/urls_test.go
@@ -6,7 +6,7 @@
 	"github.com/rackspace/gophercloud"
 )
 
-const Endpoint = "http://localhost:57909/v3/"
+const Endpoint = "http://localhost:57909/"
 
 func EndpointClient() *gophercloud.ServiceClient {
 	return &gophercloud.ServiceClient{Endpoint: Endpoint}
@@ -27,3 +27,11 @@
 		t.Fatalf("[%s] does not match expected [%s]", actual, expected)
 	}
 }
+
+func TestExtensionURL(t *testing.T) {
+	actual := ExtensionURL(EndpointClient(), "agent")
+	expected := Endpoint + "v2.0/extensions/agent"
+	if expected != actual {
+		t.Fatalf("[%s] does not match expected [%s]", actual, expected)
+	}
+}
