Smaws_Client_GameLift.CreateScriptThis API works with the following fleet types: EC2, Anywhere
Creates a new script record for your Amazon GameLift Servers Realtime script. Realtime scripts are JavaScript that provide configuration settings and optional custom game logic for your game. The script is deployed when you create a Amazon GameLift Servers Realtime fleet to host your game sessions. Script logic is executed during an active game session.
To create a new script record, specify a script name and provide the script file(s). The script files and all dependencies must be zipped into a single file. You can pull the zip file from either of these locations:
If the call is successful, a new script record is created with a unique script ID. If the script file is provided as a local file, the file is uploaded to an Amazon GameLift Servers-owned S3 bucket and the script record's storage location reflects this location. If the script file is provided as an S3 bucket, Amazon GameLift Servers accesses the file at this storage location as needed for deployment.
Learn more
Amazon GameLift Servers Amazon GameLift Servers Realtime
Set Up a Role for Amazon GameLift Servers Access
Related actions
val error_to_string :
[ Smaws_Lib.Protocols.AwsJson.error
| `ConflictException of Types.conflict_exception
| `InternalServiceException of Types.internal_service_exception
| `InvalidRequestException of Types.invalid_request_exception
| `TaggingFailedException of Types.tagging_failed_exception
| `UnauthorizedException of Types.unauthorized_exception ] ->
stringval request :
'http_type Smaws_Lib.Context.t ->
Types.create_script_input ->
(Types.create_script_output,
[> Smaws_Lib.Protocols.AwsJson.error
| `ConflictException of Types.conflict_exception
| `InternalServiceException of Types.internal_service_exception
| `InvalidRequestException of Types.invalid_request_exception
| `TaggingFailedException of Types.tagging_failed_exception
| `UnauthorizedException of Types.unauthorized_exception ])
Stdlib.resultval request_with_metadata :
'http_type Smaws_Lib.Context.t ->
Types.create_script_input ->
(Types.create_script_output Smaws_Lib.Response.t,
[> Smaws_Lib.Protocols.AwsJson.error
| `ConflictException of Types.conflict_exception
| `InternalServiceException of Types.internal_service_exception
| `InvalidRequestException of Types.invalid_request_exception
| `TaggingFailedException of Types.tagging_failed_exception
| `UnauthorizedException of Types.unauthorized_exception ]
* Smaws_Lib.Response.metadata)
Stdlib.result