Skip to main content
POST
/
api
/
v1
/
automation_executions
/
search
SearchAutomationExecutions
package main

import(
	"context"
	"github.com/conductorone/conductorone-sdk-go/pkg/models/shared"
	conductoronesdkgo "github.com/conductorone/conductorone-sdk-go"
	"log"
)

func main() {
    ctx := context.Background()

    s := conductoronesdkgo.New(
        conductoronesdkgo.WithSecurity(shared.Security{
            BearerAuth: "<YOUR_BEARER_TOKEN_HERE>",
            Oauth: "<YOUR_OAUTH_HERE>",
        }),
    )

    res, err := s.AutomationExecutionSearch.SearchAutomationExecutions(ctx, nil)
    if err != nil {
        log.Fatal(err)
    }
    if res.SearchAutomationExecutionsResponse != nil {
        // handle response
    }
}
{
  "expanded": [
    {
      "@type": "<string>"
    }
  ],
  "list": [
    {
      "automationExecution": {
        "automationTemplateId": "<string>",
        "completedAt": "2023-11-07T05:31:56Z",
        "context": {
          "context": {}
        },
        "createdAt": "2023-11-07T05:31:56Z",
        "currentVersion": 123,
        "deletedAt": "2023-11-07T05:31:56Z",
        "duration": "<string>",
        "id": "<string>",
        "isDraft": true,
        "state": "AUTOMATION_EXECUTION_STATE_UNSPECIFIED",
        "updatedAt": "2023-11-07T05:31:56Z"
      },
      "automationExecutionTriggerPath": "<string>",
      "automationPath": "<string>"
    }
  ],
  "nextPageToken": "<string>"
}

Authorizations

Authorization
string
header
required

Bearer authentication header of the form Bearer <token>, where <token> is your auth token.

Authorization
string
header
required

This API uses OAuth2 with the Client Credential flow. Client Credentials must be sent in the BODY, not the headers. For an example of how to implement this, refer to the c1TokenSource.Token() function.

Body

application/json

The SearchAutomationExecutionsRequest message.

automationTemplateId
string

The automationTemplateId field.

executionId
string<int64>

The executionId field.

executionStepStates
enum<string>[] | null

The executionStepStates field.

Available options:
AUTOMATION_EXECUTION_STATE_UNSPECIFIED,
AUTOMATION_EXECUTION_STATE_PENDING,
AUTOMATION_EXECUTION_STATE_CREATING,
AUTOMATION_EXECUTION_STATE_GET_STEP,
AUTOMATION_EXECUTION_STATE_PROCESS_STEP,
AUTOMATION_EXECUTION_STATE_COMPLETE_STEP,
AUTOMATION_EXECUTION_STATE_DONE,
AUTOMATION_EXECUTION_STATE_ERROR,
AUTOMATION_EXECUTION_STATE_TERMINATE,
AUTOMATION_EXECUTION_STATE_WAITING
expandMask
Automation Execution Expand Mask · object

The AutomationExecutionExpandMask message.

pageSize
integer<int32>

The pageSize field.

pageToken
string

The pageToken field.

query
string

The query field.

refs
Automation Execution Ref · object[] | null

The refs field.

Response

200 - application/json

Successful response

The SearchAutomationExecutionsResponse message.

expanded
object[] | null

The expanded field.

list
Automation Execution View · object[] | null

The list field.

nextPageToken
string

The nextPageToken field.