Generating new code

Creating a new client operation

If you want to create a new operation to a client, you may just generate it and complete the test stubs. Below is an example to generate an operation for DynamoDB.

  1. Clone the async-aws/aws repository.
  2. Run composer install
  3. Run ./generate DynamoDb and press "1" for generate a new operation.
  4. Select the operation you want to generate. Don't generate operations that you don't need.
  5. Use the AWS Api Reference to fill the expected Input/Result.

If you started working on a new operation, please submit a "Draft PR" to show your progress. Don't hesitate asking for help.

Creating a new client

If you want to create a new AWS client, there are a few steps to take. Below is an example for DynamoDB.

  1. Clone the async-aws/aws repository.
  2. Run composer install
  3. Copy ./src/Service/.template to ./src/Service/DynamoDb
  4. Replace all occurrences of Foobar to DynamoDb and foobar to dynamo-db
  5. Rename FoobarClient into DynamoDbClient
  6. Add dynamoDb method to the client factory src/Core/src/AwsClientFactory.php
  7. Register the service in the services section of the ./manifest.json file.
    1. Look at the official SDK for resources in ./src/data. (DynamoDB example)
    2. Add a link to source, and, if the files exists, links to documentation, example, pagination, waiter etc.
    3. Leave the methods key empty. ("methods": [])
    4. Provide the base URL to the AWS API reference (use AWS or Google)
  8. Configure the autoload section of ./composer.json to include the new service ("AsyncAws\\DynamoDb\\": "src/Service/DynamoDb/src")
  9. Do the same thing with the autoload-dev section of ./composer.json.
  10. Run composer dump-autoload
  11. Add the operations you want following the process previously defined
  12. Update the packages overview section of the root README.md file
  13. Create a ./docs/clients/dynamodb.md file documenting the client
  14. Update the ./docs/clients/index.md and ./couscous.yml files to point to the new client documentation
  15. Add the new client in ./src/Integration/Symfony/Bundle/src/DependencyInjection/AwsPackagesProvider.php
  16. Update the ./CHANGELOG.md

If you started working on a new client, please submit a "Draft PR" to show your progress. Don't hesitate asking for help.