text: user211: I need to download all the completely assembled cyanobacterial genome's GenBank file(.gbff) from NCBI(RefSeq or INSDC ftp data).
  For this I think, the steps are:
  
  Need to find the completely assembled genomes.
  find the GenBank file URL based on the taxonomic name.
  download the GenBank file(.gbff file)
  
  Is their any way to do this by using any python module or any other idea??
  
  user9608: As an alternative, you can use the NCBI Datasets CLI, in a two step process to generate a dehydrated dataset for later hydration:
  # Download metadata for all Cyanobacteria 
  # And pull out accession for 'Complete' genomes
  ./datasets assembly-descriptors taxon Cyanobacteria --limit ALL \
       | jq -r '.assemblies[].assembly | "\(.assembly_accession) \(.assembly_level)"' \
       | grep Complete \
       | cut -f 1 -d ' ' > accs.txt
  
  # Download a dehydrated dataset for the provided set of accessions
  ./datasets download assembly -i accs.txt -f 1117_complete.zip \
       --dehydrated \
       --exclude-protein \
       --exclude-rna \
       --exclude-seq \
       --exclude-gff3 \
       --include-gbff 
  
  You may be interested in some of the other files that are excluded.
  Once you have the dehydrated dataset, you can rehydrate it when you are ready to analyze the data with:
  unzip 1117_complete.zip -d 1117_complete
  ./datasets rehydrate -f 1117_complete
  
  
  user1802: Outline of solution:
  
  get this file: ftp://ftp.ncbi.nlm.nih.gov/genomes/refseq/bacteria/assembly_summary.txt
  filter for lines having "Complete Genome" in column 12
  filter for lines having a taxid (column 6) that is a descendant of taxon id 1117 (phylum Cyanobacteria), you can use nodes.dmp from ftp://ftp.ncbi.nlm.nih.gov/pub/taxonomy/taxdump.tar.gz
  The file download URL is the concatenation of column 20 and the last field of column 20, after separating it at '/', followed by appending '_genomic.gbff.gz'.  For example: ftp://ftp.ncbi.nlm.nih.gov/genomes/all/GCF/000/007/365/GCF_000007365.1_ASM736v1/GCF_000007365.1_ASM736v1_genomic.gbff.gz
  
  Edit:
  Since I will need something like that soon, I made a Perl script for downloading genomes.
  For Cyanobacteria, you would do ./download-refseq-genomes.pl 1117
  
original_text: 211: <p>I need to download all the <strong>completely assembled cyanobacterial genome</strong>'s GenBank file(.gbff) from NCBI(RefSeq or INSDC ftp data).</p>
  
  <p>For this I think, the steps are:</p>
  
  <ol>
  <li>Need to find the completely assembled genomes.</li>
  <li>find the GenBank file URL based on the taxonomic name.</li>
  <li>download the GenBank file(.gbff file)</li>
  </ol>
  
  <p>Is their any way to do this by using any python module or any other idea??</p>
   9608: <p>As an alternative, you can use the <a href="https://www.ncbi.nlm.nih.gov/datasets/docs/command-line-start/" rel="nofollow noreferrer">NCBI Datasets CLI</a>, in a two step process to generate a dehydrated dataset for later <a href="https://www.ncbi.nlm.nih.gov/datasets/docs/rehydrate/" rel="nofollow noreferrer">hydration</a>:</p>
  <pre><code># Download metadata for all Cyanobacteria 
  # And pull out accession for 'Complete' genomes
  ./datasets assembly-descriptors taxon Cyanobacteria --limit ALL \
       | jq -r '.assemblies[].assembly | &quot;\(.assembly_accession) \(.assembly_level)&quot;' \
       | grep Complete \
       | cut -f 1 -d ' ' &gt; accs.txt
  
  # Download a dehydrated dataset for the provided set of accessions
  ./datasets download assembly -i accs.txt -f 1117_complete.zip \
       --dehydrated \
       --exclude-protein \
       --exclude-rna \
       --exclude-seq \
       --exclude-gff3 \
       --include-gbff 
  </code></pre>
  <p>You may be interested in some of the other files that are excluded.</p>
  <p>Once you have the dehydrated dataset, you can rehydrate it when you are ready to analyze the data with:</p>
  <pre><code>unzip 1117_complete.zip -d 1117_complete
  ./datasets rehydrate -f 1117_complete
  </code></pre>
   1802: <p>Outline of solution:</p>
  
  <ul>
  <li>get this file: <a href="ftp://ftp.ncbi.nlm.nih.gov/genomes/refseq/bacteria/assembly_summary.txt" rel="nofollow noreferrer">ftp://ftp.ncbi.nlm.nih.gov/genomes/refseq/bacteria/assembly_summary.txt</a></li>
  <li>filter for lines having "Complete Genome" in column 12</li>
  <li>filter for lines having a taxid (column 6) that is a descendant of taxon id 1117 (phylum Cyanobacteria), you can use nodes.dmp from <a href="ftp://ftp.ncbi.nlm.nih.gov/pub/taxonomy/taxdump.tar.gz" rel="nofollow noreferrer">ftp://ftp.ncbi.nlm.nih.gov/pub/taxonomy/taxdump.tar.gz</a></li>
  <li>The file download URL is the concatenation of column 20 and the last field of column 20, after separating it at '/', followed by appending '_genomic.gbff.gz'.  For example: <a href="ftp://ftp.ncbi.nlm.nih.gov/genomes/all/GCF/000/007/365/GCF_000007365.1_ASM736v1/GCF_000007365.1_ASM736v1_genomic.gbff.gz" rel="nofollow noreferrer">ftp://ftp.ncbi.nlm.nih.gov/genomes/all/GCF/000/007/365/GCF_000007365.1_ASM736v1/GCF_000007365.1_ASM736v1_genomic.gbff.gz</a></li>
  </ul>
  
  <p>Edit:<br>
  Since I will need something like that soon, I made a <a href="https://github.com/pmenzel/download-refseq-genomes" rel="nofollow noreferrer">Perl script for downloading genomes</a>.<br>
  For Cyanobacteria, you would do <code>./download-refseq-genomes.pl 1117</code></p>
  