Skip to content

Commit 81ffb03

Browse files
authored
meta: multiple commits (#823)
feat: added more Environment RPCs feat: added Versions service feat: added Fulfillment service feat: added TextToSpeechSettings. refactor!: helper agentPath becomes projectAgentPath refactor!: helper intentPath becomes projectAgentIntentPath refactor!: helper entityTypePath becomes projectAgentEntityTypePath PiperOrigin-RevId: 372230736 Fixes #822
1 parent 342abd9 commit 81ffb03

8 files changed

+11
-11
lines changed

dialogflow/create-intent.js

+1-1
Original file line numberDiff line numberDiff line change
@@ -50,7 +50,7 @@ function main(
5050
// Construct request
5151

5252
// The path to identify the agent that owns the created intent.
53-
const agentPath = intentsClient.agentPath(projectId);
53+
const agentPath = intentsClient.projectAgentPath(projectId);
5454

5555
const trainingPhrases = [];
5656

dialogflow/list-intents.js

+1-1
Original file line numberDiff line numberDiff line change
@@ -36,7 +36,7 @@ function main(projectId = 'YOUR_PROJECT_ID') {
3636
// Construct request
3737

3838
// The path to identify the agent that owns the intents.
39-
const projectAgentPath = intentsClient.agentPath(projectId);
39+
const projectAgentPath = intentsClient.projectAgentPath(projectId);
4040

4141
console.log(projectAgentPath);
4242

dialogflow/resource.js

+1-1
Original file line numberDiff line numberDiff line change
@@ -26,7 +26,7 @@ async function deleteIntent(projectId, intentId) {
2626
// Instantiates clients
2727
const intentsClient = new dialogflow.IntentsClient();
2828

29-
const intentPath = intentsClient.intentPath(projectId, intentId);
29+
const intentPath = intentsClient.projectAgentIntentPath(projectId, intentId);
3030

3131
const request = {name: intentPath};
3232

dialogflow/system-test/create-intent.test.js

+1-1
Original file line numberDiff line numberDiff line change
@@ -38,7 +38,7 @@ describe('create intent', () => {
3838

3939
after('delete the created intent', async () => {
4040
const projectId = await client.getProjectId();
41-
const intentPath = client.intentPath(projectId, intentId);
41+
const intentPath = client.projectAgentIntentPath(projectId, intentId);
4242
const request = {name: intentPath};
4343
await client.deleteIntent(request);
4444
});

dialogflow/system-test/create-session-entity-type.test.js

+2-2
Original file line numberDiff line numberDiff line change
@@ -33,7 +33,7 @@ describe('create session entity type', () => {
3333
before('create an entity type', async () => {
3434
const projectId = await client.getProjectId();
3535
const createEntityTypeRequest = {
36-
parent: client.agentPath(projectId),
36+
parent: client.projectAgentPath(projectId),
3737
entityType: {
3838
displayName: displayName,
3939
kind: 'KIND_MAP',
@@ -57,7 +57,7 @@ describe('create session entity type', () => {
5757
after('delete the created entity type', async () => {
5858
const projectId = await client.getProjectId();
5959
const request = {
60-
name: client.entityTypePath(projectId, entityTypeId),
60+
name: client.projectAgentEntityTypePath(projectId, entityTypeId),
6161
};
6262
await client.deleteEntityType(request);
6363
});

dialogflow/system-test/delete-intent.test.js

+1-1
Original file line numberDiff line numberDiff line change
@@ -31,7 +31,7 @@ describe('delete intent', () => {
3131
before('create the intent', async () => {
3232
const projectId = await client.getProjectId();
3333
const createIntentRequest = {
34-
parent: client.agentPath(projectId),
34+
parent: client.projectAgentPath(projectId),
3535
intent: {
3636
displayName: displayName,
3737
trainingPhrases: [

dialogflow/system-test/delete-session-entity-type.test.js

+2-2
Original file line numberDiff line numberDiff line change
@@ -33,7 +33,7 @@ describe('delete session entity types', () => {
3333
// First create an entity type
3434
const projectId = await client.getProjectId();
3535
const createEntityTypeRequest = {
36-
parent: client.agentPath(projectId),
36+
parent: client.projectAgentPath(projectId),
3737
entityType: {
3838
displayName: displayName,
3939
kind: 'KIND_MAP',
@@ -74,7 +74,7 @@ describe('delete session entity types', () => {
7474
after('delete the created entity type', async () => {
7575
const projectId = await client.getProjectId();
7676
const request = {
77-
name: client.entityTypePath(projectId, entityTypeId),
77+
name: client.projectAgentEntityTypePath(projectId, entityTypeId),
7878
};
7979
await client.deleteEntityType(request);
8080
});

dialogflow/system-test/list-session-entity-types.test.js

+2-2
Original file line numberDiff line numberDiff line change
@@ -35,7 +35,7 @@ describe('list session entity types', () => {
3535
// First create an entity type
3636
const projectId = await client.getProjectId();
3737
const createEntityTypeRequest = {
38-
parent: client.agentPath(projectId),
38+
parent: client.projectAgentPath(projectId),
3939
entityType: {
4040
displayName: displayName,
4141
kind: 'KIND_MAP',
@@ -79,7 +79,7 @@ describe('list session entity types', () => {
7979
after('delete the created entity type', async () => {
8080
const projectId = await client.getProjectId();
8181
const request = {
82-
name: client.entityTypePath(projectId, entityTypeId),
82+
name: client.projectAgentEntityTypePath(projectId, entityTypeId),
8383
};
8484
await client.deleteEntityType(request);
8585
});

0 commit comments

Comments
 (0)