Re: WinSCP with S3
As in the GUI, even in the .NET assembly, the buckets are presented as root-level folders.
See https://winscp.net/eng/docs/guide_amazon_s3#buckets
So listing the root folder will give you bucket names. E.g. in C#:
That also means that to upload to the bucket, you need to use the bucket name in the target path:
See https://winscp.net/eng/docs/guide_amazon_s3#buckets
So listing the root folder will give you bucket names. E.g. in C#:
var buckets = session.ListDirectory("/").Files.Select(_ => _.Name);
That also means that to upload to the bucket, you need to use the bucket name in the target path:
session.PutFileToDirectory(@"C:\local\path\file.txt", "/bucket");