awe.sm Administration API
Creating A Project
Creates a project that belongs to a specified subscription. Allows for as much or as little initial configuration as desired.
POSTapi.awe.sm/projects/new
HTTPS is supported on this endpoint.
Required Parameters
| Parameter | Type | Description |
|---|---|---|
| subscription_key | string | The key of the subscription that owns the projects being retrieved. Found in subscription settings. |
| json | JSON string | A project object. All fields are optional except for name, which must be globally unique. See below. These values can be changed later using projects/{api_key}/update. |
Project Creation Object
| Parameter | Type | Description |
|---|---|---|
| name | string | Required. Must be globally unique. Name can only contain: a–z, A–Z, 0–9, underscores, and hyphens. Spaces are not allowed. |
| conversions | object | See Conversions Object below. |
| domains | array of strings | Domains authorized for this project. Domains must already be connected to the subscription that owns the project being created. awe.sm is available to all projects and does not need to be specified. |
| default_domain | string | The default domain for the project. Must be one of the authorized domains. Default is awe.sm. |
| admins | array of strings | Adds users as administrators. In addition to the viewer and sharer capabilities, admins are authorized to change project settings, invite users to the project, and change permissions of other users on the project. |
| sharers | array of strings | Adds users as sharers. In addition to the viewer capabilities, sharers are authorized to use the awe.sm Publisher application to post new links. |
| viewers | array of strings | Adds users as viewers. Viewers who are authorized to use the awe.sm Stats application to view reports. |
Note: Users may be identified by email address, sharer_id, or awe.sm username. New users must be identified by email address and will receive a welcome email.
Conversions Object
| Parameter | Type | Description |
|---|---|---|
| enabled | boolean | true to enable conversion tracking. false to disable. |
| domains | string or array of strings |
The hostnames of websites where conversions from shares will be tracked. Accepts 3 types of values:
|
|
goal_1_label goal_2_label goal_3_label goal_4_label goal_5_label goal_6_label goal_7_label goal_8_label goal_9_label goal_10_label |
string | The display name metadata for conversion tracking goals. 256 character limit. |
Example Project Creation Object
{
"name": "myNewProject",
"domains" : [
"examp.le",
"demo.examp.le"
],
"default_domain": "examp.le"
"admins": [
"jeremiah"
],
"sharers": [
"paul@example.com"
],
"viewers": [
"9x69x9x0-42x1-420x-9876-123139064x99"
],
"conversions": {
"enabled": true,
"domains": [
"example.com",
"www.example.com",
"example.net"
],
"goal_1_label": "Liked our Facebook Page",
"goal_2_label": "Downloaded Photo of the Day",
"goal_3_label": "Purchase"
}
}
Example
Create a new project named "myNewProject".
POST http://api.awe.sm/projects/new?subscription_key=sub-xXXxXxxX&application_key=nZurcZ&json={"name":"myNewProject"}
{
"request": {
"application_key": "nZurcZ",
"json": "{\"name\":\"myNewProject\"}",
"method": "new",
"object": "project",
"subscription_key": "sub-xXXxXxxX"
},
"response": {
"project": {
"admins": [],
"api_key": "6xxxxxxxxx58xx0xxx74xx3x76xx83x6x34xx48x7xxxx55x167037818d65x66x",
"created_at": "2011-10-25 00:43:49",
"default_domain": "awe.sm",
"domains": [],
"name": "myNewProject",
"sharers": [],
"updated_at": "2011-10-25 00:43:49",
"viewers": []
}
}
}
Last updated 2012-01-09