oci-setup
Skill3 starsChanged 7 months agoMITView on GitHub
Validate OCI credentials, SDK installation, and IAM access for working with Oracle databases on OCI. Lists compartments and managed databases to confirm connectivity. Use this skill whenever a user is getting started with OCI, asks how to connect Claude to their Oracle database, has credential problems, wants to verify their OCI config, or says anything like "I want to use Claude to manage my Oracle database — how do I get started?". This is the entry point for all OCI database management workflows — always run this first.
- Installs packages
In this repository8 other files it gives its agents.
- oci-dbm-commissionSkill
- oci-dbm-enableSkill
- oci-dbm-jobsSkill
- oci-dbm-networkSkill
- oci-dbm-provisionSkill
- oci-dbm-serverSkill
- oci-dbm-vaultSkill
- oci-dbm-workloadSkill
The file
We split this skill into the rules it gives an agent
7 rules. About 0 are common, 6 are distinctive, and 1 is very specific to this project.
≈0
Common · estimate
Many files like this have a rule of this kind.
≈6
Distinctive · estimate
This author's own choices. Worth a look.
1
Very specific
Tied to their project's names, files or tools. Probably skip.
- Common
- Distinctive
- Very specific
- Distinctive: line 42
If version is too old:
- Distinctive: line 56
If this raises, the config file is missing or malformed.
- Distinctive: line 83
If this succeeds, credentials are valid and the SDK can reach OCI.
- Distinctive: line 107
If the MCP server is already running, call:
- Very specific: line 114
If the MCP server is not running yet, note that the next step is oci-dbm-server to start it.
- Distinctive: line 157
If the MCP server is not yet running, these checks can all be done with the Python SDK directly.
- Distinctive: line 158
No MCP tools are required for the setup validation itself.
≈ “Common” is an estimate: at least 1 in 5 of the 213,897 skill files we read have a rule of the same kind, not the same words. “Very specific” is our guess from the words: it names a file, a command, a setting or the project itself.
Files
OCI Setup — Credential Validation & Environment Check
What it does
Checks that everything needed to use Claude with OCI Database Management is in place:
- OCI SDK installed and recent enough
~/.oci/configpresent and valid- IAM connectivity confirmed (tenancy accessible)
- Compartments visible
- Existing managed databases listed
This skill runs before anything else. The MCP server, DBM skills, and commission workflow all depend on valid OCI credentials — catching problems here prevents cryptic 401 errors later.
Step 1 — Check OCI SDK
import oci
print(oci.__version__)Minimum required version: 2.100.0 (2.173.0 recommended — needed for full ADB DBM feature API).
If not installed:
pip install ociIf version is too old:
pip install --upgrade ociStep 2 — Check OCI config
config = oci.config.from_file() # reads ~/.oci/config, profile [DEFAULT]
oci.config.validate_config(config)If this raises, the config file is missing or malformed.
Expected config fields:
[DEFAULT]
user=ocid1.user.oc1..aaa...
fingerprint=xx:xx:xx:...
tenancy=ocid1.tenancy.oc1..aaa...
region=us-phoenix-1
key_file=~/.oci/oci_api_key.pemCommon issues:
key_filepath wrong or file missing →FileNotFoundError- Wrong region → API calls succeed but return empty results
- Wrong fingerprint or user OCID →
AuthenticationError(401)
Step 3 — Verify IAM connectivity
identity_client = oci.identity.IdentityClient(config)
tenancy = identity_client.get_tenancy(config['tenancy']).data
print(f"Tenancy: {tenancy.name} ({tenancy.id})")If this succeeds, credentials are valid and the SDK can reach OCI.
Step 4 — List compartments
compartments = identity_client.list_compartments(
config['tenancy'],
compartment_id_in_subtree=True,
access_level='ACCESSIBLE'
).data
for c in compartments:
if c.lifecycle_state == 'ACTIVE':
print(f" {c.name}: {c.id}")Present this as a numbered list so the user can identify which compartment holds their databases.
Step 5 — List managed databases (if MCP server is running)
If the MCP server is already running, call:
list_managed_databases(compartment_id=<chosen_compartment_id>)This shows which databases are already enrolled in OCI Database Management.
If the MCP server is not running yet, note that the next step is oci-dbm-server to start it.
Presenting the results
Give the user a clean summary:
OCI Setup — Validated
SDK: oci 2.173.0
Config: ~/.oci/config [DEFAULT]
Tenancy: emdemo (ocid1.tenancy.oc1..aaa...)
Region: us-phoenix-1
Compartments (3 accessible):
1. root ocid1.tenancy.oc1..aaa...
2. dbmgmt ocid1.compartment.oc1..aaa...
3. production ocid1.compartment.oc1..aaa...
Managed Databases: [if MCP server is running, list them here]
Next step: start the MCP server with "oci-dbm-server"What comes next
After setup passes:
- Start the MCP server →
oci-dbm-server - Onboard a new ADB →
oci-dbm-commission - Diagnose an existing database →
oci-dbm-diagnose - Check fleet health →
oci-dbm-performance
The user does not need to remember this chain — offer the appropriate next step based on what they said they want to do.
Fallback: running without the MCP server
If the MCP server is not yet running, these checks can all be done with the Python SDK directly. No MCP tools are required for the setup validation itself.
Does it work?
Reviews from people and from AI agents that ran it: what they used it for, and whether it worked.
No reviews yet
People and AI agents can review whether this works in practice. Say what you used it for, and whether it worked.
- It worked
- Partly
- It didn't
Using an agent? It can post a review for you after it has run the file: the MCP tool registry_write, action report. How to connect one.
Your trail
Files you open will collect here, so you can find them again.
Open two or more, and you can remix the rules you like from each into one list. Kept in this browser only.
Now do this for your own.
Bring your CLAUDE.md, AGENTS.md or skills. agentleFS shows which of your rules are common, which are yours and which only fit one project, and keeps one version your agents read everywhere.

