How to use the @aws-sdk/middleware-header-default.headerDefault function in @aws-sdk/middleware-header-default

To help you get started, we’ve selected a few @aws-sdk/middleware-header-default examples, based on popular ways it is used in public projects.

Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues immediately.

github aws / aws-sdk-js-v3 / packages / client-s3-node / commands / GetBucketVersioningCommand.ts View on Github external
model: this.model
    };
    stack.add(
      __aws_sdk_bucket_endpoint_middleware.bucketEndpointMiddleware({
        forcePathStyle: configuration.forcePathStyle,
        preformedBucketEndpoint: configuration.bucketEndpoint,
        useAccelerateEndpoint: configuration.useAccelerateEndpoint,
        useDualstackEndpoint: configuration.useDualstackEndpoint
      }),
      {
        step: "build",
        priority: 0
      }
    );
    stack.add(
      __aws_sdk_middleware_header_default.headerDefault({
        "Content-Type": "application/octet-stream"
      }),
      {
        step: "build",
        priority: -50,
        tags: { "Content-Type": true }
      }
    );
    return stack.resolve(
      handler(
        handlerExecutionContext
      ),
      handlerExecutionContext
    );
  }
}
github aws / aws-sdk-js-v3 / clients / browser / client-s3-browser / commands / PutObjectCommand.ts View on Github external
};
    stack.add(
      __aws_sdk_bucket_endpoint_middleware.bucketEndpointMiddleware({
        forcePathStyle: configuration.forcePathStyle,
        preformedBucketEndpoint: configuration.bucketEndpoint,
        useAccelerateEndpoint: configuration.useAccelerateEndpoint,
        useDualstackEndpoint: configuration.useDualstackEndpoint
      }),
      {
        step: "build",
        priority: 0
      }
    );
    if (configuration.disableBodySigning) {
      stack.add(
        __aws_sdk_middleware_header_default.headerDefault({
          "x-amz-content-sha256": "UNSIGNED-PAYLOAD"
        }),
        {
          step: "build",
          priority: 100,
          tags: { BODY_CHECKSUM: true, UNSIGNED_PAYLOAD: true }
        }
      );
    }
    stack.add(
      __aws_sdk_ssec_middleware.ssecMiddleware({
        base64Encoder: configuration.base64Encoder,
        hashConstructor: configuration.md5,
        ssecProperties: {
          $serverSideEncryptionKey: {
            targetProperty: "SSECustomerKey",
github aws / aws-sdk-js-v3 / packages / client-s3-node / commands / HeadBucketCommand.ts View on Github external
model: this.model
    };
    stack.add(
      __aws_sdk_bucket_endpoint_middleware.bucketEndpointMiddleware({
        forcePathStyle: configuration.forcePathStyle,
        preformedBucketEndpoint: configuration.bucketEndpoint,
        useAccelerateEndpoint: configuration.useAccelerateEndpoint,
        useDualstackEndpoint: configuration.useDualstackEndpoint
      }),
      {
        step: "build",
        priority: 0
      }
    );
    stack.add(
      __aws_sdk_middleware_header_default.headerDefault({
        "Content-Type": "application/octet-stream"
      }),
      {
        step: "build",
        priority: -50,
        tags: { "Content-Type": true }
      }
    );
    return stack.resolve(
      handler(handlerExecutionContext),
      handlerExecutionContext
    );
  }
}
github aws / aws-sdk-js-v3 / packages / client-s3-browser / commands / GetObjectTorrentCommand.ts View on Github external
model: this.model
    };
    stack.add(
      __aws_sdk_bucket_endpoint_middleware.bucketEndpointMiddleware({
        forcePathStyle: configuration.forcePathStyle,
        preformedBucketEndpoint: configuration.bucketEndpoint,
        useAccelerateEndpoint: configuration.useAccelerateEndpoint,
        useDualstackEndpoint: configuration.useDualstackEndpoint
      }),
      {
        step: "build",
        priority: 0
      }
    );
    stack.add(
      __aws_sdk_middleware_header_default.headerDefault({
        "Content-Type": "application/octet-stream"
      }),
      {
        step: "build",
        priority: -50,
        tags: { "Content-Type": true }
      }
    );
    return stack.resolve(
      handler(
        handlerExecutionContext
      ),
      handlerExecutionContext
    );
  }
}
github aws / aws-sdk-js-v3 / clients / node / client-mediastore-data-node / commands / PutObjectCommand.ts View on Github external
clientStack: __aws_sdk_middleware_stack.MiddlewareStack<
      InputTypesUnion,
      OutputTypesUnion,
      _stream.Readable
    >,
    configuration: MediaStoreDataResolvedConfiguration
  ): __aws_sdk_types.Handler {
    const { handler } = configuration;
    const stack = clientStack.concat(this.middlewareStack);

    const handlerExecutionContext: __aws_sdk_types.HandlerExecutionContext = {
      logger: {} as any,
      model: this.model
    };
    stack.add(
      __aws_sdk_middleware_header_default.headerDefault({
        "X-Amz-Content-Sha256": "UNSIGNED_PAYLOAD"
      }),
      {
        step: "build",
        priority: 100,
        tags: { UNSIGNED_PAYLOAD: true }
      }
    );
    return stack.resolve(
      handler(handlerExecutionContext),
      handlerExecutionContext
    );
  }
}
github aws / aws-sdk-js-v3 / clients / browser / client-s3-browser / commands / HeadBucketCommand.ts View on Github external
model: this.model
    };
    stack.add(
      __aws_sdk_bucket_endpoint_middleware.bucketEndpointMiddleware({
        forcePathStyle: configuration.forcePathStyle,
        preformedBucketEndpoint: configuration.bucketEndpoint,
        useAccelerateEndpoint: configuration.useAccelerateEndpoint,
        useDualstackEndpoint: configuration.useDualstackEndpoint
      }),
      {
        step: "build",
        priority: 0
      }
    );
    stack.add(
      __aws_sdk_middleware_header_default.headerDefault({
        "Content-Type": "application/octet-stream"
      }),
      {
        step: "build",
        priority: -50,
        tags: { "Content-Type": true }
      }
    );
    return stack.resolve(
      handler(handlerExecutionContext),
      handlerExecutionContext
    );
  }
}
github aws / aws-sdk-js-v3 / clients / node / client-s3-node / commands / GetBucketPolicyCommand.ts View on Github external
model: this.model
    };
    stack.add(
      __aws_sdk_bucket_endpoint_middleware.bucketEndpointMiddleware({
        forcePathStyle: configuration.forcePathStyle,
        preformedBucketEndpoint: configuration.bucketEndpoint,
        useAccelerateEndpoint: configuration.useAccelerateEndpoint,
        useDualstackEndpoint: configuration.useDualstackEndpoint
      }),
      {
        step: "build",
        priority: 0
      }
    );
    stack.add(
      __aws_sdk_middleware_header_default.headerDefault({
        "Content-Type": "application/octet-stream"
      }),
      {
        step: "build",
        priority: -50,
        tags: { "Content-Type": true }
      }
    );
    return stack.resolve(
      handler(
        handlerExecutionContext
      ),
      handlerExecutionContext
    );
  }
}
github aws / aws-sdk-js-v3 / packages / client-s3-node / commands / GetBucketCorsCommand.ts View on Github external
model: this.model
    };
    stack.add(
      __aws_sdk_bucket_endpoint_middleware.bucketEndpointMiddleware({
        forcePathStyle: configuration.forcePathStyle,
        preformedBucketEndpoint: configuration.bucketEndpoint,
        useAccelerateEndpoint: configuration.useAccelerateEndpoint,
        useDualstackEndpoint: configuration.useDualstackEndpoint
      }),
      {
        step: "build",
        priority: 0
      }
    );
    stack.add(
      __aws_sdk_middleware_header_default.headerDefault({
        "Content-Type": "application/octet-stream"
      }),
      {
        step: "build",
        priority: -50,
        tags: { "Content-Type": true }
      }
    );
    return stack.resolve(
      handler(handlerExecutionContext),
      handlerExecutionContext
    );
  }
}
github aws / aws-sdk-js-v3 / clients / node / client-s3-node / commands / GetBucketAccelerateConfigurationCommand.ts View on Github external
model: this.model
    };
    stack.add(
      __aws_sdk_bucket_endpoint_middleware.bucketEndpointMiddleware({
        forcePathStyle: configuration.forcePathStyle,
        preformedBucketEndpoint: configuration.bucketEndpoint,
        useAccelerateEndpoint: configuration.useAccelerateEndpoint,
        useDualstackEndpoint: configuration.useDualstackEndpoint
      }),
      {
        step: "build",
        priority: 0
      }
    );
    stack.add(
      __aws_sdk_middleware_header_default.headerDefault({
        "Content-Type": "application/octet-stream"
      }),
      {
        step: "build",
        priority: -50,
        tags: { "Content-Type": true }
      }
    );
    return stack.resolve(
      handler<
        GetBucketAccelerateConfigurationInput,
        GetBucketAccelerateConfigurationOutput
      >(handlerExecutionContext),
      handlerExecutionContext
    );
  }
github aws / aws-sdk-js-v3 / clients / node / client-s3-node / commands / GetBucketWebsiteCommand.ts View on Github external
model: this.model
    };
    stack.add(
      __aws_sdk_bucket_endpoint_middleware.bucketEndpointMiddleware({
        forcePathStyle: configuration.forcePathStyle,
        preformedBucketEndpoint: configuration.bucketEndpoint,
        useAccelerateEndpoint: configuration.useAccelerateEndpoint,
        useDualstackEndpoint: configuration.useDualstackEndpoint
      }),
      {
        step: "build",
        priority: 0
      }
    );
    stack.add(
      __aws_sdk_middleware_header_default.headerDefault({
        "Content-Type": "application/octet-stream"
      }),
      {
        step: "build",
        priority: -50,
        tags: { "Content-Type": true }
      }
    );
    return stack.resolve(
      handler(
        handlerExecutionContext
      ),
      handlerExecutionContext
    );
  }
}

@aws-sdk/middleware-header-default

[![NPM version](https://img.shields.io/npm/v/@aws-sdk/middleware-header-default/latest.svg)](https://www.npmjs.com/package/@aws-sdk/middleware-header-default) [![NPM downloads](https://img.shields.io/npm/dm/@aws-sdk/middleware-header-default.svg)](https:/

Apache-2.0
Latest version published 2 years ago

Package Health Score

77 / 100
Full package analysis

Popular @aws-sdk/middleware-header-default functions

Similar packages