Home > Storage > PowerScale (Isilon) > Product Documentation > Protocols > Dell PowerScale: OneFS S3 API Guide > x-isi-path extended header
When creating a bucket through S3, OneFS provides an optional S3 extension to specify a OneFS directory as a bucket path. The following is an example of adding the extended header through boto3.
import boto3
HOST=<ip/fqdn> # Your SmartConnect name or cluster IP goes here
USERNAME='1_local_user01_accid' # Your access ID
USERKEY='mWQbXkadl2CR_x2_WRj4tYu_d11j' # Your secret key
URL = 'http://{}:9020'.format(HOST)
s3 = boto3.resource('s3')
session = boto3.Session()
s3client = session.client(service_name='s3',aws_access_key_id=USERNAME,aws_secret_access_key=USERKEY,endpoint_url=URL,use_ssl=False,verify=False)
bucket_name='bucket01'
bucket _path = "/ifs/data/s3buckets/{}".format(bucket_name)
headers = {'x-isi-path': bucket_path}
# pass in custom headers before CreateBucket call
add_headers = (lambda **kwargs: kwargs['params']['headers'].update(headers))
s3client.meta.events.register('before-call.s3.CreateBucket', add_headers)
s3client.create_bucket(Bucket=bkt_name)