MatterPhase
Description: Represents a phase or stage within a matter. Matters are typically broken down into phases to track progress and organize work.
Type Structure
Type Name: MatterPhase
Fields:
Id:String!- Unique identifier for the matter phaseNumber:String!- Matter phase reference number (e.g., PH-2023-001-A)Name:String!- Descriptive name of the phase
Example Usage
The MatterPhase type is typically returned as part of matter queries:
curl -X POST \
-H "Content-Type: application/json" \
-H "Authorization: Bearer YOUR_ACCESS_TOKEN" \
-d '{
"query": "query { AllMatters { Id Number Name Phases { Id Number Name } } }"
}' \
https://sandbox.drivepractice.com/api/v1/graphqlExample Response
{
"data": {
"AllMatters": [
{
"Id": "5f8d0d5a7b3e4f1234567890",
"Number": "MAT-2023-001",
"Name": "Corporate Restructuring Project",
"Phases": [
{
"Id": "5f8d0d5a7b3e4f1234567892",
"Number": "PH-2023-001-A",
"Name": "Discovery Phase"
},
{
"Id": "5f8d0d5a7b3e4f1234567893",
"Number": "PH-2023-001-B",
"Name": "Implementation Phase"
},
{
"Id": "5f8d0d5a7b3e4f1234567894",
"Number": "PH-2023-001-C",
"Name": "Review Phase"
}
]
}
]
}
}Field Details
Id
- Type:
String!(Non-null String) - Description: System-generated unique identifier for the matter phase
- Example:
"5f8d0d5a7b3e4f1234567892" - Usage: Used for internal references and relationships
Number
- Type:
String!(Non-null String) - Description: Human-readable reference number assigned to the matter phase
- Example:
"PH-2023-001-A" - Format: Typically follows a pattern like
PH-YYYY-NNN-Xwhere YYYY is the year, NNN is the matter number, and X is the phase letter - Usage: Used for phase identification in documents and communications
Name
- Type:
String!(Non-null String) - Description: Descriptive name of the phase
- Example:
"Discovery Phase" - Usage: Display purposes and phase identification
Relationships
The MatterPhase type has relationships with:
- Matter: Each phase belongs to exactly one matter (one-to-many relationship from Matter to MatterPhase)
- Activity: Activities are associated with specific matter phases for time tracking
Best Practices
- Phase Identification: Use the
Numberfield for phase references in external systems - Complete Context: When querying phases, always include them within the context of their parent matter
- Time Tracking: Associate time entries with specific phases for accurate billing and reporting
- Progress Tracking: Use phases to monitor progress through different stages of a matter
Common Use Cases
- Project Phasing: Break down matters into logical phases or stages
- Time Entry: Record time spent on specific phases of a matter
- Progress Tracking: Monitor which phases have been completed
- Resource Allocation: Allocate resources based on current phase
- Billing: Create phase-specific invoices
- Reporting: Generate reports by phase for better project insights
Phase Examples
Typical Matter Phases
- Discovery Phase: Initial research and information gathering
- Analysis Phase: Review and analyze collected information
- Implementation Phase: Execute the planned actions
- Review Phase: Quality assurance and final review
- Completion Phase: Final delivery and handover
Query Examples
Get All Matters with Phases
cURL
curl -X POST \
-H "Content-Type: application/json" \
-H "Authorization: Bearer YOUR_ACCESS_TOKEN" \
-d '{
"query": "query { AllMatters { Id Number Name Phases { Id Number Name } } }"
}' \
https://sandbox.drivepractice.com/api/v1/graphqlGet Complete Matter Information with Phases
cURL
curl -X POST \
-H "Content-Type: application/json" \
-H "Authorization: Bearer YOUR_ACCESS_TOKEN" \
-d '{
"query": "query { AllMatters { Id Number Name Client { Id Number Name } Phases { Id Number Name } } }"
}' \
https://sandbox.drivepractice.com/api/v1/graphqlIntegration with Activities
Matter phases are used in the CreateActivityForUserWithNumbers mutation to associate time entries with specific phases:
curl -X POST \
-H "Content-Type: application/json" \
-H "Authorization: Bearer YOUR_ACCESS_TOKEN" \
-d '{
"query": "mutation CreateActivity($input: CreateActivityForUserWithNumbers!) { CreateActivityForUserWithNumbers(createActivityForUserWithNumbers: $input) { Id } }",
"variables": {
"input": {
"UserEmail": "john.doe@company.com",
"ApplicableDate": "2023-11-15",
"MatterNumber": "MAT-2023-001",
"MatterPhaseNumber": "PH-2023-001-A",
"ActivityTypeNumber": "ACT-001",
"UnitNumber": "UNIT-001",
"Description": "Conducted legal research during discovery phase",
"BillableQuantity": 3.5,
"NonBillableQuantity": 1.0
}
}
}' \
https://sandbox.drivepractice.com/api/v1/graphqlIn this example, the MatterPhaseNumber field specifies which phase the activity belongs to, enabling detailed tracking and reporting by phase.