All URIs are relative to https://app.asana.com/api/1.0
Method | HTTP request | Description |
---|---|---|
createProjectBrief | POST /projects/{project_gid}/project_briefs | Create a project brief |
deleteProjectBrief | DELETE /project_briefs/{project_brief_gid} | Delete a project brief |
getProjectBrief | GET /project_briefs/{project_brief_gid} | Get a project brief |
updateProjectBrief | PUT /project_briefs/{project_brief_gid} | Update a project brief |
GetProjectBrief200Response createProjectBrief(projectGid, updateProjectBriefRequest, opts)
Create a project brief
Creates a new project brief. Returns the full record of the newly created project brief.
import Asana from 'asana';
let defaultClient = Asana.ApiClient.instance;
// Configure OAuth2 access token for authorization: oauth2
let oauth2 = defaultClient.authentications['oauth2'];
oauth2.accessToken = 'YOUR ACCESS TOKEN';
// Configure Bearer access token for authorization: personalAccessToken
let personalAccessToken = defaultClient.authentications['personalAccessToken'];
personalAccessToken.accessToken = "YOUR ACCESS TOKEN"
let apiInstance = new Asana.ProjectBriefsApi();
let projectGid = 1331; // String | Globally unique identifier for the project.
let updateProjectBriefRequest = new Asana.UpdateProjectBriefRequest(); // UpdateProjectBriefRequest | The project brief to create.
let opts = {
'optPretty': true, // Boolean | Provides “pretty” output. Provides the response in a “pretty” format. In the case of JSON this means doing proper line breaking and indentation to make it readable. This will take extra time and increase the response size so it is advisable only to use this during debugging.
'optFields': ["followers","assignee"] // [String] | Defines fields to return. Some requests return *compact* representations of objects in order to conserve resources and complete the request more efficiently. Other times requests return more information than you may need. This option allows you to list the exact set of fields that the API should be sure to return for the objects. The field names should be provided as paths, described below. The id of included objects will always be returned, regardless of the field options.
};
apiInstance.createProjectBrief(projectGid, updateProjectBriefRequest, opts, (error, data, response) => {
if (error) {
console.error(error);
} else {
console.log('API called successfully. Returned data: ' + data);
}
});
Name | Type | Description | Notes |
---|---|---|---|
projectGid | String | Globally unique identifier for the project. | |
updateProjectBriefRequest | UpdateProjectBriefRequest | The project brief to create. | |
optPretty | Boolean | Provides “pretty” output. Provides the response in a “pretty” format. In the case of JSON this means doing proper line breaking and indentation to make it readable. This will take extra time and increase the response size so it is advisable only to use this during debugging. | [optional] |
optFields | [String] | Defines fields to return. Some requests return compact representations of objects in order to conserve resources and complete the request more efficiently. Other times requests return more information than you may need. This option allows you to list the exact set of fields that the API should be sure to return for the objects. The field names should be provided as paths, described below. The id of included objects will always be returned, regardless of the field options. | [optional] |
- Content-Type: application/json
- Accept: application/json
DeleteAttachment200Response deleteProjectBrief(projectBriefGid, opts)
Delete a project brief
Deletes a specific, existing project brief. Returns an empty data record.
import Asana from 'asana';
let defaultClient = Asana.ApiClient.instance;
// Configure OAuth2 access token for authorization: oauth2
let oauth2 = defaultClient.authentications['oauth2'];
oauth2.accessToken = 'YOUR ACCESS TOKEN';
// Configure Bearer access token for authorization: personalAccessToken
let personalAccessToken = defaultClient.authentications['personalAccessToken'];
personalAccessToken.accessToken = "YOUR ACCESS TOKEN"
let apiInstance = new Asana.ProjectBriefsApi();
let projectBriefGid = 12345; // String | Globally unique identifier for the project brief.
let opts = {
'optPretty': true, // Boolean | Provides “pretty” output. Provides the response in a “pretty” format. In the case of JSON this means doing proper line breaking and indentation to make it readable. This will take extra time and increase the response size so it is advisable only to use this during debugging.
'optFields': ["followers","assignee"] // [String] | Defines fields to return. Some requests return *compact* representations of objects in order to conserve resources and complete the request more efficiently. Other times requests return more information than you may need. This option allows you to list the exact set of fields that the API should be sure to return for the objects. The field names should be provided as paths, described below. The id of included objects will always be returned, regardless of the field options.
};
apiInstance.deleteProjectBrief(projectBriefGid, opts, (error, data, response) => {
if (error) {
console.error(error);
} else {
console.log('API called successfully. Returned data: ' + data);
}
});
Name | Type | Description | Notes |
---|---|---|---|
projectBriefGid | String | Globally unique identifier for the project brief. | |
optPretty | Boolean | Provides “pretty” output. Provides the response in a “pretty” format. In the case of JSON this means doing proper line breaking and indentation to make it readable. This will take extra time and increase the response size so it is advisable only to use this during debugging. | [optional] |
optFields | [String] | Defines fields to return. Some requests return compact representations of objects in order to conserve resources and complete the request more efficiently. Other times requests return more information than you may need. This option allows you to list the exact set of fields that the API should be sure to return for the objects. The field names should be provided as paths, described below. The id of included objects will always be returned, regardless of the field options. | [optional] |
- Content-Type: Not defined
- Accept: application/json
GetProjectBrief200Response getProjectBrief(projectBriefGid, opts)
Get a project brief
Get the full record for a project brief.
import Asana from 'asana';
let defaultClient = Asana.ApiClient.instance;
// Configure OAuth2 access token for authorization: oauth2
let oauth2 = defaultClient.authentications['oauth2'];
oauth2.accessToken = 'YOUR ACCESS TOKEN';
// Configure Bearer access token for authorization: personalAccessToken
let personalAccessToken = defaultClient.authentications['personalAccessToken'];
personalAccessToken.accessToken = "YOUR ACCESS TOKEN"
let apiInstance = new Asana.ProjectBriefsApi();
let projectBriefGid = 12345; // String | Globally unique identifier for the project brief.
let opts = {
'optPretty': true, // Boolean | Provides “pretty” output. Provides the response in a “pretty” format. In the case of JSON this means doing proper line breaking and indentation to make it readable. This will take extra time and increase the response size so it is advisable only to use this during debugging.
'optFields': ["followers","assignee"] // [String] | Defines fields to return. Some requests return *compact* representations of objects in order to conserve resources and complete the request more efficiently. Other times requests return more information than you may need. This option allows you to list the exact set of fields that the API should be sure to return for the objects. The field names should be provided as paths, described below. The id of included objects will always be returned, regardless of the field options.
};
apiInstance.getProjectBrief(projectBriefGid, opts, (error, data, response) => {
if (error) {
console.error(error);
} else {
console.log('API called successfully. Returned data: ' + data);
}
});
Name | Type | Description | Notes |
---|---|---|---|
projectBriefGid | String | Globally unique identifier for the project brief. | |
optPretty | Boolean | Provides “pretty” output. Provides the response in a “pretty” format. In the case of JSON this means doing proper line breaking and indentation to make it readable. This will take extra time and increase the response size so it is advisable only to use this during debugging. | [optional] |
optFields | [String] | Defines fields to return. Some requests return compact representations of objects in order to conserve resources and complete the request more efficiently. Other times requests return more information than you may need. This option allows you to list the exact set of fields that the API should be sure to return for the objects. The field names should be provided as paths, described below. The id of included objects will always be returned, regardless of the field options. | [optional] |
- Content-Type: Not defined
- Accept: application/json
GetProjectBrief200Response updateProjectBrief(projectBriefGid, updateProjectBriefRequest, opts)
Update a project brief
An existing project brief can be updated by making a PUT request on the URL for that project brief. Only the fields provided in the `data` block will be updated; any unspecified fields will remain unchanged. Returns the complete updated project brief record.
import Asana from 'asana';
let defaultClient = Asana.ApiClient.instance;
// Configure OAuth2 access token for authorization: oauth2
let oauth2 = defaultClient.authentications['oauth2'];
oauth2.accessToken = 'YOUR ACCESS TOKEN';
// Configure Bearer access token for authorization: personalAccessToken
let personalAccessToken = defaultClient.authentications['personalAccessToken'];
personalAccessToken.accessToken = "YOUR ACCESS TOKEN"
let apiInstance = new Asana.ProjectBriefsApi();
let projectBriefGid = 12345; // String | Globally unique identifier for the project brief.
let updateProjectBriefRequest = new Asana.UpdateProjectBriefRequest(); // UpdateProjectBriefRequest | The updated fields for the project brief.
let opts = {
'optPretty': true, // Boolean | Provides “pretty” output. Provides the response in a “pretty” format. In the case of JSON this means doing proper line breaking and indentation to make it readable. This will take extra time and increase the response size so it is advisable only to use this during debugging.
'optFields': ["followers","assignee"] // [String] | Defines fields to return. Some requests return *compact* representations of objects in order to conserve resources and complete the request more efficiently. Other times requests return more information than you may need. This option allows you to list the exact set of fields that the API should be sure to return for the objects. The field names should be provided as paths, described below. The id of included objects will always be returned, regardless of the field options.
};
apiInstance.updateProjectBrief(projectBriefGid, updateProjectBriefRequest, opts, (error, data, response) => {
if (error) {
console.error(error);
} else {
console.log('API called successfully. Returned data: ' + data);
}
});
Name | Type | Description | Notes |
---|---|---|---|
projectBriefGid | String | Globally unique identifier for the project brief. | |
updateProjectBriefRequest | UpdateProjectBriefRequest | The updated fields for the project brief. | |
optPretty | Boolean | Provides “pretty” output. Provides the response in a “pretty” format. In the case of JSON this means doing proper line breaking and indentation to make it readable. This will take extra time and increase the response size so it is advisable only to use this during debugging. | [optional] |
optFields | [String] | Defines fields to return. Some requests return compact representations of objects in order to conserve resources and complete the request more efficiently. Other times requests return more information than you may need. This option allows you to list the exact set of fields that the API should be sure to return for the objects. The field names should be provided as paths, described below. The id of included objects will always be returned, regardless of the field options. | [optional] |
- Content-Type: application/json
- Accept: application/json