-
Notifications
You must be signed in to change notification settings - Fork 2
W-19995335: wire up compile api #173
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Conversation
src/agent.ts
Outdated
| const apiEnv = 'api.salesforce.com'; | ||
| const url = `https://${apiEnv}/einstein/ai-agent/v1.1/authoring/compile`; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
could remove apiEnv and put it in the URL string now
test/nuts/agent.nut.ts
Outdated
|
|
||
| describe('compileAgentScript', () => { | ||
| it('should compile a lululemon agent script successfully', async () => { | ||
| // Read the lululemon agent script from the project |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
we may want to obfuscate the lulu example some, and make it generic since this is OSS
src/agent.ts
Outdated
| throw SfError.create({ | ||
| name: 'CompileAgentScriptError', | ||
| message: 'Error when compiling AgentScript', |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I know this was here, but we should just SfError.wrap(errror) - I think that'll preserve more information from the real error on the server
What does this PR do?
Callout to the real compile API.
What issues does this PR fix or reference?
@W-19995335@