I would like to know if I can call http request as a state in Step Functions in order to perform some actions, such as adding a new item to DynamoDb. Could it be done without using lambda functions?
As an example, I would like to create something similar to this Step Function in GCP in AWS-
main:
params: [args]
steps:
- storeMetadata:
call: http.request
args:
url: ${"https://firestore.googleapis.com/v1/projects/" + projectId + "/databases/(default)/documents/pictures/" + file + "?updateMask.fieldPaths=color&updateMask.fieldPaths=labels&updateMask.fieldPaths=created"}
auth:
type: OAuth2
method: PATCH
body:
name: ${"projects/" + projectId + "/databases/(default)/documents/(bucket name)/" + file}
fields:
color:
stringValue: "blue"
result: storeMetadataResponse
such as adding a new item to DynamoDb
Step Functions can interact with DynamoDB directly, so there is no need to craft a raw HTTP request for this.
Step Function can also call an AWS API Gateway directly.
To answer the more generic part of your question, no, Step Functions cannot call an HTTP service like an external API directly. For that you would need to use a Lambda function.